-
-
Notifications
You must be signed in to change notification settings - Fork 197
Allow for apps to disable page reload livesyncs #1517
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
Comments
I would suggest an option in package.json (of course under nativescript key), so you can just define that you always want restart for the current project. |
Ping @rosen-vladimirov @ligaz This is critical for our Angular integration. |
@atanasovg , @hdeshev "nativescript": {
"reloadOnSync": false,
"tns-android": "1.7.0"
} We can add it by default in our Angular template and I'll make sure CLI will copy it to project's package.json when this template is used. |
I like it. Do we need to copy it in the CLI if it's present in the template already? Just to clarify, setting |
@hdeshev yes, I've not been very creative with the name 😸 As per the copying from template to project's package.json - yes, CLI works with the project, not with the template's package.json. The only case where we check the template's package.json is on |
Isn't this responsibility of the I'm imagining we provide the right hook (similar to the way we want transpilers to define which files to ignore for sync) so that the |
👍 I like the idea of calling a callback which we can override in a plugin. That would probably require a change to tns-core-modules (which is probably OK). |
Livesync hook and a way to force full livesync are added. This plugin shows how to do it. With this hook when changing any type of file full sync will be executed. |
Already done. |
Why
Page reload syncs are completely unsupported in Angular apps, and realoading a page completely breaks the app.
What
We need a way to disable page reload syncs for Angular apps, and always restart the app.
How
Certainly not like this. Funny hacks aside, here's what comes to mind:
package.json
for anangular2
dependency.--no-page-reloads
nativescript-angular
code overrides and disables page reloads.The text was updated successfully, but these errors were encountered: