Altaba77 / ngx-walkthrough

A walkthrough/on-boarding/tour guide/learning page component which is responsive, dynamic, easy to use
MIT License
8 stars 8 forks source link

walkthrough tag not recognised in angular 6 #7

Closed shubhd47 closed 6 years ago

shubhd47 commented 6 years ago

Done the same as the instructions I don't know if anything else need to be imported . I am new to angular please help on this.

Altaba77 commented 6 years ago

Hello,

can you provide more informations about what you did (module import, and html code) and what is the error generated.

shubhd47 commented 6 years ago

import { WalkthroughModule } from 'ngx-walkthrough'; imports: [WalkthroughModule ]

I have imported this in app.module.ts and when i use the walkthrough tags in app.component.html it is not recognised

this tag not recognised . Please tell me if i am doing anything wrong
Altaba77 commented 6 years ago

I did few tests with angular 6 and I do not find any problems with tag that is not recognized.

Check my repository walkthrough-tests maybe it can help you to figure it out.

What is your error stack trace ?

shubhd47 commented 6 years ago

No problem ,now its working maybe I have been doing something wrong. But still the tags are showing in red color. Is that a problem?

One more query, How to define steps in it?Is there a way I can bind a function with the "Got It" button?

Altaba77 commented 6 years ago

I think it is because some of the dependencies of the library are outdated I should update them when I have time.

To define steps I guess you want highlight different elements one after the other. So you need to create different walkthrough, show the first one and hide the other with ngIf. Then you use the output emit when the walkthrough is close (see Example 4 of the readme) to bind a function and change the value of the good variable to show the next walkthrough.

If you need I can provide an example in walkthrough-tests later.

Regards.

askanium commented 6 years ago

I am receiving supposedly the same error the OP was getting. Angular version: 6.0.7

Did import the component in app.module.ts:

import { WalkthroughModule } from 'ngx-walkthrough';

@NgModule({
  declarations: [
    AppComponent,
  ],
  imports: [
    BrowserModule,
    WalkthroughModule,
  ],
  bootstrap: [AppComponent]
})
export class AppModule { }

When building the project, I'm getting this error:

ERROR in ./src/app/app.module.ngfactory.js
Module not found: Error: Can't resolve 'walkthrough' in '/<path_to_project>/src/app'