Updating version 5.1.x so it works with Ionic v3 Production Builds. #90
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When trying to use this library in Ionic v3 it was working great until I tried to do a production build. Production builds in Ionic use the Ahead-of-Time compiling and various other settings, but I was getting the following error.
` Error during template compile of 'NgxBraintreeModule' Function calls are not supported in decorators but 'ɵmakeDecorator' was called in 'NgModule' 'NgModule' calls 'ɵmakeDecorator'.
I did some research and found this article github issue. angular/angular-cli#3854. Which stated that a solution for this is to including the paths for the angular node_modules in the tsconfig.ts file.This then packages the project without the node_modules directory. Once I did this and copied the packaged files over to my Ionic project I was able to do a production build and run the app successfully.