U
U
Umid2017-03-25 23:38:14
Angular
Umid, 2017-03-25 23:38:14

Error: Error: Unexpected value 'undefined' declared by the module 'ComponentsModule', why?

Good evening. Need help. For the second hour I have been struggling with a solution (Google did not help).
The above error is displayed.
Briefly about the code:
fe92d906194a40438216fccf39b628a2.png
By the name of the error, I can assume that the ComponentsModule module declares the InputComponent component as undefined.
Code from the InputComponent file:

import { Component } from "@angular/core";
import { InputInnerComponent } from "./input-inner";

@Component({
  moduleId: module.id,
  selector: "input-comp",
  templateUrl: "input.component.html",
})
export class InputComponent {}

If you need any more files, please unsubscribe.
Thank you in advance.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
U
Umid, 2017-03-26
@DarCKoder

Found what the problem is.
In case anyone has a similar error:
In the barrel file, I first exported all the components, and then the module.
It was necessary to export the module as the latest.
Source:
https://github.com/angular/angular-cli/issues/1831...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question