nebular icon indicating copy to clipboard operation
nebular copied to clipboard

nb-tag-list not working

Open Sonali-Sharma-tech opened this issue 3 years ago • 2 comments

Issue type

I'm submitting a ... (check one with "x")

  • [x] bug report
  • [ ] feature request

Issue description

Current behavior:

I used the code given on https://akveo.github.io/nebular/docs/components/tag/overview#nbtaglistcomponent in my home.component.ts It gives me error as shown below : before_declaration Now, when I declared NbTagListComponent in HomeModule, It gives me error as shown below : after_declaration

Expected behavior:

It should work as showed on nebular site https://akveo.github.io/nebular/docs/components/tag/overview#nbtaglistcomponent expected

Steps to reproduce:

  1. Use the template and .ts code in your component.
  2. Add required methods and imports.
  3. Initialise 'trees' array with some static values.
  4. Compile

Related code: HomeModule.ts

import { ReactiveFormsModule } from '@angular/forms';
import { FormsModule } from './../forms/forms.module';
import { NbCardModule,
   NbButtonModule, NbTagModule,
    NbInputModule, NbFormFieldModule, NbAutocompleteModule, NbIconModule, NbTagListComponent } from '@nebular/theme';
import { UtilityService } from './../../@core/utils/utility.service';
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';

import { HomeRoutingModule } from './home-routing.module';


@NgModule({
  declarations: [NbTagListComponent],
  imports: [
    HomeRoutingModule,
    CommonModule,
    FormsModule,
    ReactiveFormsModule,
    NbCardModule,
    NbButtonModule,
    NbTagModule,
    NbInputModule,
    NbFormFieldModule,
    NbAutocompleteModule,
    NbIconModule,
  ],
  providers: [UtilityService],
})
export class HomeModule { }

Other information:

npm, node, OS, Browser

Angular CLI: 12.1.0
Node: 12.14.1
 npm: 6.13.4
OS: darwin x64
Browser: Chrome

Angular, Nebular

Nebular : 8.0.0

Sonali-Sharma-tech avatar Jan 12 '22 16:01 Sonali-Sharma-tech

Hi, could you attach a stackBlitz example, please? Cause it seems to be working.

katebatura avatar Jan 14 '22 13:01 katebatura

was getting the same error however in the documentation its not mentioned to install the module ,one needs to install the module NbTagModule in the modules.ts file then this error will go away

worldfellow avatar Apr 11 '22 10:04 worldfellow