marcj / angular2-localstorage

Angular 2+ decorator to save and restore variables/class properties to HTML5 LocalStorage automatically.
303 stars 107 forks source link

how to use no prefix #82

Open louisdoe opened 7 years ago

louisdoe commented 7 years ago

Hi

I got this in my code:


@NgModule({
  declarations: [
   //...
  ],
  imports: [
    IonicModule.forRoot(MyApp),
    LocalStorageModule.withConfig({
      // prefix: 'MyApp',
      storageType: 'localStorage'
    })
  ],

but I still have a default prefix "ls".

Can you help me remove this ?

Thanks

thor-schueler commented 7 years ago

@louisdoe: could you please post the component or service code where you are trying to use the decorator or storage service?

Also, are you sure you are in the right repo? The module for this package is named WebStorageModule, not LocalStorageModule and it does not support the .withConfig() method...