Skip to content

Commit 4ecd84c

Browse files
committed
fix indent problem in CodeSnippet
1 parent a7b4a2e commit 4ecd84c

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

src/components/right-sidebar/CodeSnippet.vue

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -236,20 +236,21 @@ export default {
236236
}
237237
const htmlBinding = this.componentMap[this.activeComponent].htmlList
238238
239-
data += " data () {\n return {\n"
239+
data += " data() {\n return {\n"
240240
htmlBinding.forEach(el => {
241241
if (el.binding !== '') {
242-
data += ` "${el.binding}": "PLACEHOLDER FOR VALUE", `
242+
data += ` "${el.binding}": "PLACEHOLDER FOR VALUE", `
243243
data += '\n'
244244
}
245245
})
246-
data += ` \n } \n `
246+
data += ` }`
247+
data += ` \n }, \n `
247248
248249
249250
// if true add computed section and populate with state
250251
let computed = "";
251252
if (this.componentMap[this.activeComponent].state.length) {
252-
computed += " computed: {";
253+
computed += " computed: {";
253254
computed += "\n ...mapState([";
254255
this.componentMap[this.activeComponent].state.forEach((state) => {
255256
computed += `\n "${state}", `;
@@ -298,7 +299,7 @@ export default {
298299
output += imports + "\nexport default defineComponent ({\n name: '" + componentName + "';";
299300
} else {
300301
output = "\n\n<script>\n";
301-
output += imports + "\nexport default {\n name: '" + componentName + "';";
302+
output += imports + "\nexport default {\n name: '" + componentName + "'";
302303
}
303304
output += ",\n components: {\n";
304305
output += childrenComponentNames + " },\n";

0 commit comments

Comments
 (0)