Skip to content

Commit

Permalink
Code review feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
srtfisher committed Feb 22, 2023
1 parent 85da58c commit 4de472b
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
6 changes: 4 additions & 2 deletions bin/create-block/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,18 @@ module.exports = {
editorScript: 'file:index.ts',
editorStyle: 'file:index.css',
style: ['file:style-index.css'],
render: 'file:render.php',
},
variants: {
static: {},
'static-javascript': {
blockTemplatesPath: path.join(__dirname, 'templates', 'block', 'javascript'),
},
dynamic: {},
dynamic: {
render: 'file:render.php',
},
'dynamic-javascript': {
blockTemplatesPath: path.join(__dirname, 'templates', 'block', 'javascript'),
render: 'file:render.php',
},
},
blockTemplatesPath: path.join(__dirname, 'templates', 'block', 'typescript'),
Expand Down
4 changes: 2 additions & 2 deletions bin/create-block/templates/block/javascript/save.jsx.mustache
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ import { useBlockProps } from '@wordpress/block-editor';
*/
export default function save() {
return (
<p { ...useBlockProps.save() }>
{ '{{title}} – hello from the saved content!' }
<p {...useBlockProps.save()}>
{'{{title}} – hello from the saved content!'}
</p>
);
}
Expand Down
4 changes: 2 additions & 2 deletions bin/create-block/templates/block/typescript/save.tsx.mustache
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ import { useBlockProps } from '@wordpress/block-editor';
*/
export default function save() {
return (
<p { ...useBlockProps.save() }>
{ '{{title}} – hello from the saved content!' }
<p {...useBlockProps.save()}>
{'{{title}} – hello from the saved content!'}
</p>
);
}
Expand Down

0 comments on commit 4de472b

Please sign in to comment.