Skip to content

Commit a7b4a2e

Browse files
committed
use props instead of data to label the props in the export default
1 parent e870527 commit a7b4a2e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/components/right-sidebar/CodeSnippet.vue

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -226,12 +226,12 @@ export default {
226226
// if true add data section and populate with props
227227
let data = "";
228228
if (this.componentMap[this.activeComponent].props.length) {
229-
data += " data () {\n return {";
229+
data += " props: {";
230230
this.componentMap[this.activeComponent].props.forEach((prop) => {
231-
data += `\n ${prop}: "PLACEHOLDER FOR VALUE",`;
231+
data += `\n ${prop}: "PLACEHOLDER FOR VALUE",`;
232232
});
233233
data += "\n";
234-
data += " }\n";
234+
//data += " }\n";
235235
data += " },\n";
236236
}
237237
const htmlBinding = this.componentMap[this.activeComponent].htmlList

0 commit comments

Comments
 (0)