question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

angular2-schema-form 404 (Not Found)

See original GitHub issue

When adding the FieldRegistryService at bootstrap i get the following error:

zone.js:101 GET http://localhost:4200/angular2-schema-form 404 (Not Found)

I am using angular cli.

//main.ts
import { bootstrap } from '@angular/platform-browser-dynamic';
import { enableProdMode } from '@angular/core';
import { AppComponent, environment } from './app/';
import { HTTP_PROVIDERS } from '@angular/http';
import { appRouterProviders } from './app/app.routes';
import { FieldRegistryService } from "angular2-schema-form";

if (environment.production) {
  enableProdMode();
}

bootstrap(AppComponent, [appRouterProviders, HTTP_PROVIDERS, FieldRegistryService]);

Any idea what might be missing?

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:6

github_iconTop GitHub Comments

1reaction
jsalamandercommented, Jul 27, 2016

Nope. But I figured out that I had to add the following:

// angular-cli-build.js -> vendorNpmFiles
'angular2-schema-form/dist/*.js'

After that run ng build. If this was successful you should find the files in dist/angular2-schema-form

Then make sure your system-config.ts looks like this:

const map: any = {
  'angular2-schema-form': 'vendor/angular2-schema-form/dist'
};

/** User packages configuration. */
const packages: any = {
  'angular2-schema-form': {
    format: 'cjs',
    defaultExtension: 'js',
    main: 'index.js'
  },
};

If everything worked fine the 404 should be gone.

This issue can therefore be closed.

1reaction
jsalamandercommented, Jul 25, 2016

Thx for the quick response. I installed it trough npm as written in the README. The IDE is able to find the references… Adding provideForms() and disableDeprecatedForm() didn’t help.

Read more comments on GitHub >

github_iconTop Results From Across the Web

angular - XHR error (404) loading angular2/forms - Stack Overflow
@angular is working, i am including the angular dependency as "@angular/core": "^2.0.0", I got it working changing the @angular/forms to @angular/http, not sure ......
Read more >
Using the REST Adapter with Oracle Integration Generation 2
The HTTP 404, 404 Not Found, and 404 error message is a Hypertext Transfer Protocol (HTTP) standard response code, in computer network communications, ......
Read more >
https://developer.crif.com/apis/hellocrif/1-0-0/re...
... desc)' style: form explode: false schema: type: array items: type: string ... '404': description: Consent not found content: application/json: schema: ...
Read more >
Handling Errors - FastAPI
The status codes in the 400 range mean that there was an error from the client. Remember all those "404 Not Found" errors...
Read more >
Using Angular routes in a single-page application
It is possible for a user to try to access a route that you have not defined. To account for this behavior, the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found