Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

demo not working : Cannot find module '@nativescript/localize/hooks/before-watchPatterns.js' #544

Open
alexist opened this issue Nov 7, 2023 · 1 comment

Comments

@alexist
Copy link

alexist commented Nov 7, 2023

Hi,

Angular demo apps is not working.

Here the steps i follow :

git clone [email protected]:NativeScript/plugins.git
cd plugins
npm run setup
npm start

within npm start :

  • @nativescript.build-all
  • apps.demo.ios

The log :

―――――――――――――――――――――――― 
Running NativeScript CLI within apps/demo
 
ns debug ios --no-hmr --force
 
---
Searching for devices...
Preparing project...
webpack is watching the files...
assets by path *.js 9.43 MiB
  asset vendor.js 6.95 MiB [compared for emit] (name: vendor) (id hint: defaultVendor)
  asset bundle.js 2.34 MiB [emitted] [compared for emit] (name: bundle)
  asset packages_contacts_models_contact_ios_ts.js 56.7 KiB [compared for emit]
  asset packages_contacts_worker-get-contacts-by-name_ios_ts-_package_json.js 26 KiB [compared for emit]
  asset packages_contacts_worker-get-all-contacts_ios_ts-_package_json.js 25.7 KiB [compared for emit]
  asset runtime.js 12.4 KiB [compared for emit] (name: runtime)
  asset packages_theme-switcher_theme-loader_js_tools_demo_theme-switcher_themes_red_scss.js 4.42 KiB [compared for emit]
  asset packages_theme-switcher_theme-loader_js_tools_demo_theme-switcher_themes_green_scss.js 4.22 KiB [compared for emit]
  asset packages_theme-switcher_theme-loader_js_tools_demo_theme-switcher_themes_default_scss.js 3.2 KiB [compared for emit]
asset images/bigpic.jpg 15.4 MiB [compared for emit] [from: ../../tools/images/bigpic.jpg] [copied]
asset fonts/Linearicons-Free.ttf 79.7 KiB [compared for emit] [from: src/fonts/Linearicons-Free.ttf] [copied]
asset logos/ns-logo.png 28.4 KiB [compared for emit] [from: ../../tools/assets/logos/ns-logo.png] [copied]
asset tns_modules/inspector_modules.js 1.22 KiB [compared for emit] (name: tns_modules/inspector_modules)
Entrypoint bundle 9.31 MiB = runtime.js 12.4 KiB vendor.js 6.95 MiB bundle.js 2.34 MiB
Entrypoint tns_modules/inspector_modules 6.97 MiB = runtime.js 12.4 KiB vendor.js 6.95 MiB tns_modules/inspector_modules.js 1.22 KiB
runtime modules 9.24 KiB 24 modules
orphan modules 11.4 KiB [orphan] 7 modules
modules by path ../../ 3.02 MiB
  modules by path ../../node_modules/ 2.65 MiB 338 modules
  modules by path ../../packages/ 304 KiB 70 modules
  modules by path ../../tools/demo/ 74.2 KiB 41 modules
modules by path ./src/ 409 KiB
  modules by path ./src/plugin-demos/ 343 KiB 70 modules
  modules by path ./src/*.ts 861 bytes 3 modules
  modules by path ./src/*.xml 4.05 KiB 2 modules
  modules by path ./src/modals/ 888 bytes 2 modules
  ./src/ sync \.(xml%7Cjs%7C(?<%21\.d\.)ts%7Cs?css)$ 2.72 KiB [built] [code generated]
  ./src/app.scss 57.9 KiB [built] [code generated]
external "~/package.json" 42 bytes [optional] [built] [code generated]

WARNING in ./src/plugin-demos/imagepicker.xml
Module Warning (from ../../node_modules/@nativescript/webpack/dist/loaders/xml-namespace-loader/index.js):
Invalid character in entity name
Line: 20
Column: 51
Char: &
 @ ./src/ sync \.(xml%7Cjs%7C(?<%21\.d\.)ts%7Cs?css)$ ./plugin-demos/imagepicker.xml
 @ ../../node_modules/@nativescript/webpack/dist/stubs/virtual-entry-typescript.js 3:16-103

1 warning has detailed information that is not shown.
Use 'stats.errorDetails: true' resp. '--stats-error-details' to show it.

webpack 5.89.0 compiled with 1 warning in 6189 ms
Webpack compilation complete. Watching for file changes.
Cannot find module '@nativescript/localize/hooks/before-watchPatterns.js'
Require stack:
- /Users/alexist/plugins/apps/demo/hooks/before-watchPatterns/nativescript-localize.js
- /Users/alexist/.nvm/versions/node/v18.16.1/lib/node_modules/nativescript/lib/common/services/hooks-service.js
- /Users/alexist/.nvm/versions/node/v18.16.1/lib/node_modules/nativescript/lib/common/yok.js
- /Users/alexist/.nvm/versions/node/v18.16.1/lib/node_modules/nativescript/lib/bootstrap.js
- /Users/alexist/.nvm/versions/node/v18.16.1/lib/node_modules/nativescript/lib/nativescript-cli.js
- /Users/alexist/.nvm/versions/node/v18.16.1/lib/node_modules/nativescript/bin/tns
Done.

 

 >  NX   Running target ios for project demo and 71 tasks it depends on failed
 

My environment :

  • os : macos
  • yarn : 1.22.19
  • node : v18.16.1
  • npm : 8.19.4
@glorious73
Copy link

After deleting the folders node-modules, platform, and hooks, and deleting the file package-lock.json. Then, hitting npm install followed by ns run android or ns run ios, it worked for me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants