Skip to content
This repository was archived by the owner on Aug 7, 2021. It is now read-only.

CLI removes tns_modules in platforms #5

Closed
petekanev opened this issue Jul 12, 2016 · 7 comments
Closed

CLI removes tns_modules in platforms #5

petekanev opened this issue Jul 12, 2016 · 7 comments

Comments

@petekanev
Copy link

After the prepare-hook is executed the tns_modules folder is completely wiped from platforms/../src/main/assets/app where non-js files, xmls, and image resources may reside.

@blagoev @jasssonpet

@petekanev
Copy link
Author

petekanev commented Jul 12, 2016

We can consider removing all .js files in tns_modules thus leaving just the resources that may be referred to from the javascript during runtime, and also leave bundle.js, and tns-java-classes in addition when building for android.

@hdeshev
Copy link
Contributor

hdeshev commented Jul 25, 2016

An alternative solution to this problem would be to provide webpack loaders for known resource types, so that those get bundled as well.

What's the specific case here? Do we have a sample app that needs to reference something from tns_modules?

@gsaadeh
Copy link

gsaadeh commented Sep 21, 2016

I am running into what I believe is a similar issue. When I run the app without the bundle it works just fine. After adding webpack and running the app, I get the following error:

Could not find module 'data/observable'. Computed path '/Users/George/Library/Developer/CoreSimulator/Devices/FFF2D358-AC9C-46B1-8200-8E367588D9A3/data/Containers/Bundle/Application/9CB23FDF-570A-4646-BB92-72F09B5FB50D/sample.app/app/tns_modules/data/observable'

P.S: I am not using angular2

@markosko
Copy link

I have same either i got error on data/observable or application missing in tns_modules folder even on newly created app and bundled i get error but not sure if this is same issue or its something as for new issue

@gsaadeh
Copy link

gsaadeh commented Sep 22, 2016

I believe it's the same error since I saw the same application error that you mentioned as well. I did a rm -rf tns_modules and then tns install but nothing helped.

@hdeshev
Copy link
Contributor

hdeshev commented Dec 5, 2016

This should be resolved with [email protected] and [email protected]

@hdeshev hdeshev closed this as completed Dec 5, 2016
@gsaadeh
Copy link

gsaadeh commented Dec 5, 2016

Thanks @hdeshev I'll give it a try

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

No branches or pull requests

4 participants