-
-
Notifications
You must be signed in to change notification settings - Fork 228
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
incompatible with angular >= 6.0.0 #129
Comments
Good point. I'd happily accept a PR that switched the http resolver from |
For anyone interested in a quick workaround for Angular, I made this fork where I removed the HTTP(S) feature. I modified the README to include directions for publishing it to a local NPM repository via Verdaccio and some other steps you need to take inside your Angular app. (See this SO answer). This fork is not a good starting point for a PR. It's just a hacky workaround for those that don't need to resolve HTTP(s) references. |
I'm facing the same issue here. @Bakerburgh I've tried your fork, but getting the following error - could you possibly provide a little guidance here? I've checked the project out and npm installed it into my own project from a local directory rather than via a local npm registry.
[EDIT] My bad - I forgot to run npm install within the json-schema-ref-parser module. More or less working now, Thanks for your fork! |
Hi, I am also facing this issue. I am using Angular 8 and SwaggerParser is failing because of this. In my scenario, I can't use the hacky solution due to some constraints. |
same here, I'm using Angular 9 and json-schema-ref-parse 9.0.1 but I get the same error. |
Hi, Same here... :( Are there any plans to fix this issue in the near future? Regards, |
still getting this while using angular 9, no fix that i can find |
Is there one of you people in here who would send a PR? This is a free tool, and people experiencing problems are often the best people to be solving those problems. Otherwise you're asking somebody to carve time out of their day to fix something that they don't need for their personal projects, or their day job, or anything else, other than helping folks out. People do like helping folks out, but there are lots of other folks wanting help with lots of other things, so... maybe somebody here could step up and take a go at the suggestion James made last year?
|
For those who don't require resolution of external references, it shouldn't be a requirement at all to load any http module, which causes needless bundle bloat. It should be optional. |
i got it working, add this to package.json & reinstall:
and add this to polyfill.ts
|
If this still needs fixing please do send a PR, otherwise I am glad we have a workaround! :) |
Subject of the issue
Because json-schema-ref-parser requires node http & https, it cannot be used in Angular applications that use angular-cli >= 6.0.0
See this comment from angular-cli:
angular/angular-cli#9827 (comment)
Your environment
angular>= 6.0
Expected behavior
I can use json-schema-ref-parser in my app and ng serve does not fail
Actual behavior
ng serve fails with
The text was updated successfully, but these errors were encountered: