angular2-seed editorconfig travis-ci karma npm

Modular starter (seed) project for Angular 2 apps with fast, statically typed build

SOLVED!

I needed to import Ng2BootstrapModule into every sub-NgModule that uses it - rather than just the main root NgModule.

Repo updated with the fix.

Problem getting ng2-bootstrap to work in angular2-seed

This repo is a fork of https://github.com/mgechev/angular2-seed with https://github.com/valor-software/ng2-bootstrap added.

However it doesn’t work because the ng2-bootstrap elements are not recognised by Angular which results in errors like this:

zone.js?1474384853974:344 Unhandled Promise rejection: Template parse errors:
'tab' is not a known element:
1. If 'tab' is an Angular component, then verify that it is part of this module.
2. If 'tab' is a Web Component then add "CUSTOM_ELEMENTS_SCHEMA" to the '@NgModule.schema' of this component to suppress this message. ("

<tabset>
  [ERROR ->]<tab>1</tab>
  <tab>2</tab>
</tabset>
"): [email protected]:2
'tab' is not a known element:
1. If 'tab' is an Angular component, then verify that it is part of this module.
2. If 'tab' is a Web Component then add "CUSTOM_ELEMENTS_SCHEMA" to the '@NgModule.schema' of this component to suppress this message. ("
<tabset>
  <tab>1</tab>
  [ERROR ->]<tab>2</tab>
</tabset>
"): [email protected]:2

Try it

$ npm i
$ npm start

Check the console.

What have I done?

Installed ng2-bootstrap with npm:

$ npm install ng2-bootstrap --save

Updated the SYSTEM config here: tools/config/project.config.ts

this.SYSTEM_CONFIG_DEV.paths['ng2-bootstrap'] =
  `${this.APP_BASE}node_modules/ng2-bootstrap/ng2-bootstrap.js`;

this.SYSTEM_BUILDER_CONFIG.packages['ng2-bootstrap'] = {
    main: 'ng2-bootstrap.js',
    defaultExtension : 'js'
};

Imported Ng2BootstrapModule into the NgModule in src/client/app/app.module.ts

And finally added some basic tabs to the home component HTML:

<tabset>
  <tab>1</tab>
  <tab>2</tab>
</tabset>

Related Repositories

angular2-seed

angular2-seed

:seedling: A simple Angular 2 seed featuring Angular 2 and Webpack 2 by @AngularClass ...

angular2-react-native-seed

angular2-react-native-seed

A seed project to create a native mobile application with Angular 2 and React Native ...

angular2-login-seed

angular2-login-seed

Seed app featuring Angular2, Node.js + Express, and OAuth login support via Passport ...

angular2-seed

angular2-seed

Seed project to run angular2 out of the box, integrated with wepack and babel ...


Top Contributors

mgechev ludohenin d3viant0ne Shyam-Chen tarlepp NathanWalker Nightapes TheDonDope nareshbhatia hank-ehly kiuka daniru jesperronn vyakymenko danielcrisp sasikumardr aboeglin nulldev07 gkalpak ryzy sfabriece jerryorta-dev pgrzeszczak eppsilon natarajanmca11 e-oz LuxDie JakePartusch JayKan JohnCashmore

Releases

-   2.0.0 zip tar
-   2.0.0-rc.7 zip tar
-   2.0.0-rc.6 zip tar
-   2.0.0-rc.5 zip tar
-   2.0.0-rc.4 zip tar
-   2.0.0-rc.3 zip tar
-   2.0.0-rc.2 zip tar
-   2.0.0-rc.1 zip tar
-   2.0.0-rc.0 zip tar
-   2.0.0-beta.17 zip tar
-   2.0.0-beta.16 zip tar
-   2.0.0-beta.15 zip tar
-   2.0.0-beta.14 zip tar
-   2.0.0-beta.13 zip tar
-   2.0.0-beta.12 zip tar
-   2.0.0-beta.11 zip tar
-   2.0.0-beta.10 zip tar
-   2.0.0-beta.9 zip tar
-   2.0.0-beta.8 zip tar
-   2.0.0-beta.7 zip tar
-   2.0.0-beta.6 zip tar
-   2.0.0-beta.5 zip tar
-   2.0.0-beta.4 zip tar
-   2.0.0-beta.3 zip tar
-   2.0.0-beta.2 zip tar
-   2.0.0-beta.1 zip tar
-   2.0.0-beta.0 zip tar
-   2.0.0-alpha.55 zip tar
-   2.0.0-alpha.54 zip tar
-   2.0.0-alpha.53 zip tar