To work on this library locally with another project (e.g., tablogs_mobile_app), follow these steps:
In this library project (tablogs-plugins), run the build command in watch mode:
npm run watchIn your application project (tablogs_mobile_app):
-
Update
package.jsonto point to the local build:"dependencies": { "form": "file:../tablogs-plugins/dist/form" }
-
Run
npm install. -
Enable
preserveSymlinksinangular.jsonunder thebuildoptions and intsconfig.jsonto ensure the application can resolve dependencies correctly:angular.json:
"architect": { "build": { "options": { "preserveSymlinks": true } } }
tsconfig.json:
"compilerOptions": { "preserveSymlinks": true }
This setup allows you to make changes in the library and have them immediately reflected in the application without needing to publish to a registry.
ng generate component my-feature --project=my-plugin --standalone
To generate a new component within a specific plugin, use the following command:
ng generate component <component-name> --project=<project-name>Example for generating a component in the form project:
ng generate component components/my-new-component --project=form
```-+-+-+-+-+
sometimes it dont work
plugin
rm -rf .angular/cache && npm run watch form
web
ng build --configuration=development && ng serve
mobile
ng build --configuration=development && ionic serve