The NPM ALways do that .. and this code runs easly when i register the block as a plugin .. but when iuse the webpack do that !
<s> [webpack.Progress] 99% done plugins
<s> [webpack.Progress] 99% done plugins
<s> [webpack.Progress] 99%
asset main.js 6.46 KiB [compared for emit] (name: main)
runtime modules 937 bytes 4 modules
cacheable modules 7.36 KiB
./src/index.js 499 bytes [built] [code generated]
./src/Blocks/aboutus.js 6.44 KiB [built] [code generated] [1 error]
./src/js/gutenberg/blocks/firstRightWay/first.js 435 bytes [built] [code generated] [1 error]
ERROR in ./src/Blocks/aboutus.js 68:8
Module parse failed: Unexpected token (68:8)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
|
| return ([
> <InspectorControls style={{ marginBottom: "40px" }}>
| <PanelBody>
| <p>Select The Image !</p>
@ ./src/index.js 6:0-48 7:0-12
ERROR in ./src/js/gutenberg/blocks/firstRightWay/first.js 9:15
Module parse failed: Unexpected token (9:15)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
| category: 'design',
| edit() {
> return <div>Hello World, step 1 (from the editor).</div>
| },
| save() {
@ ./src/index.js 15:0-66 17:0-5
webpack 5.69.1 compiled with 2 errors in 264 ms
<s> [webpack.Progress] 99% cache store build dependencies
<s> [webpack.Progress] 99% cache store build dependencies
<s> [webpack.Progress] 99% cache begin idle
<s> [webpack.Progress] 99% cache begin idle
<s> [webpack.Progress] 100%
there’s any package or anything make it like that i never used .. but it mostly same package.json that was runs