Not able to generate new component
See original GitHub issueGetting exception while running npm run generate component Square
Output:
npm run generate component Square
> react-daisyui@2.0.1 generate
> plop "component" "Square"
/Users/****/Desktop/Temp/react-daisyui/node_modules/plop/bin/plop.js:3
import { Plop, run } from "../src/plop.js";
^^^^^^
SyntaxError: Cannot use import statement outside a module
at Module._compile (internal/modules/cjs/loader.js:892:18)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:973:10)
at Module.load (internal/modules/cjs/loader.js:812:32)
at Function.Module._load (internal/modules/cjs/loader.js:724:14)
at Function.Module.runMain (internal/modules/cjs/loader.js:1025:10)
at internal/main/run_main_module.js:17:11
Expected: create new component
Issue Analytics
- State:
- Created a year ago
- Comments:12
Top Results From Across the Web
Angular CLI generate component issue
Try ng g c my-component --module app.module (or --module ../module.app , or however many parent levels are needed). – Andy King.
Read more >Cannot create components with CLI on Windows #7960
Create a new project using ng new PROJECT-NAME · Create an apps folder inside of the src folder. · Move everything in src/app...
Read more >ng generate component using the CLI
ng generate component is a simple one-line command which creates different files and a folder, and it references the newly created component ......
Read more >Angular components overview
Run the ng generate component <component-name> command, where <component-name> is the name of your new component. By default, this command creates the following ......
Read more >Canvas component overview (contains video) - Power Apps
Learn about how to create reusable components for canvas apps. ... are scoped to the component instance and not shared with the app....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Working great after updated to v14… Thank you for the support @benjitrosch
Thanks @bannarisoftwares. I will take a look!