Closed NathanaelA closed 8 years ago
Hey @NathanaelA,
Is this still the case on your side? If not feel free to close the issue :smile:
Wow, this is an old issue. I think we can probably close this one. If someone runs into "replace of undefined" they should run into this issue and figure out what the issue is. :grinning:
First, The tns run fails because tns prepare fails. So the issue is with the tns prepare ios code.
In the older version of NativeScript (unless I understood wrong way back then) you would add any new resources to the xcode project from the App_Resources/ios folder and tell it to copy the resources. So while doing some documentation I added a new resource to App_Resources/ios folder, opened XCode, and then added the file to my code project from the App_Resource/ios folder, marking the copy resource checkbox.
After doing that, tns prepare fails with "Cannot call method 'replace' of undefined"
Unless I am now mistaken, the proper location and what appears to work is linking it to the resources in the platforms/ios/PROJECTNAME/Resources. So I'm back up and running fine.
However, TNS never should fail in a fashion that leaves the developer totally scratching his head with what is wrong...