本文整理匯總了TypeScript中@ionic/storage.IonicStorageModule類的典型用法代碼示例。如果您正苦於以下問題:TypeScript IonicStorageModule類的具體用法?TypeScript IonicStorageModule怎麽用?TypeScript IonicStorageModule使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
在下文中一共展示了IonicStorageModule類的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1: beforeEach
beforeEach(async(() => {
eventsSpy = jasmine.createSpyObj('Events', ['subscribe']);
menuSpy = jasmine.createSpyObj('MenuController', ['toggle', 'enable']);
routerSpy = jasmine.createSpyObj('Router', ['navigateByUrl']);
userDataSpy = jasmine.createSpyObj('UserData', ['isLoggedIn', 'logout']);
statusBarSpy = jasmine.createSpyObj('StatusBar', ['styleDefault']);
splashScreenSpy = jasmine.createSpyObj('SplashScreen', ['hide']);
platformReadySpy = Promise.resolve();
platformSpy = jasmine.createSpyObj('Platform', { ready: platformReadySpy });
TestBed.configureTestingModule({
declarations: [AppComponent],
imports: [IonicStorageModule.forRoot()],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
providers: [
{ provide: Events, useValue: eventsSpy },
{ provide: MenuController, useValue: menuSpy },
{ provide: Router, useValue: routerSpy },
{ provide: UserData, useValue: userDataSpy },
{ provide: StatusBar, useValue: statusBarSpy },
{ provide: SplashScreen, useValue: splashScreenSpy },
{ provide: Platform, useValue: platformSpy }
]
}).compileComponents();
}));
示例2: beforeEach
beforeEach(async(() => {
TestBed.configureTestingModule({
imports: [TranslateModule.forRoot(), IonicStorageModule.forRoot()],
declarations: [SettingsPage],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
providers: [Network]
}).compileComponents();
}));
示例3: beforeEach
beforeEach(async(() => {
TestBed.configureTestingModule({
imports: [ReactiveFormsModule, TranslateModule.forRoot(), IonicStorageModule.forRoot(), RouterTestingModule.withRoutes([])],
declarations: [LoginPage],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
providers: [HttpClient, HttpHandler, HTTP, Network, GooglePlus]
}).compileComponents();
}));
示例4: beforeEach
beforeEach(async(() => {
TestBed.configureTestingModule({
imports: [
IonicStorageModule.forRoot(),
TranslateModule.forRoot(),
RouterTestingModule.withRoutes([])
],
declarations: [LogoutPage],
schemas: [CUSTOM_ELEMENTS_SCHEMA]
}).compileComponents();
}));
示例5: beforeEach
beforeEach(async(() => {
TestBed.configureTestingModule({
imports: [
TranslateModule.forRoot(),
PipesModule,
IonicStorageModule.forRoot(),
RouterTestingModule.withRoutes([])
],
declarations: [ObservationsPage],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
providers: [HttpClient, HttpHandler, HTTP, Network, File]
}).compileComponents();
}));
示例6: beforeEach
beforeEach(async(() => {
const menuSpy = jasmine.createSpyObj('MenuController', [
'toggle',
'enable'
]);
const routerSpy = jasmine.createSpyObj('Router', ['navigateByUrl']);
TestBed.configureTestingModule({
declarations: [TutorialPage],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
imports: [IonicStorageModule.forRoot()],
providers: [
{ provide: MenuController, useValue: menuSpy },
{ provide: Router, useValue: routerSpy }
]
}).compileComponents();
}));
示例7: beforeEach
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [
MyApp,
HomePage,
WelcomePage,
InfoPage,
ScanSessionContextMenuPopover,
QrCodePairingModal,
MainMenuPopover,
SettingsPage,
],
imports: [
BrowserModule,
IonicStorageModule.forRoot(),
QRCodeModule,
ClipboardModule,
DragulaModule.forRoot(),
IonicModule.forRoot(MyApp,
{
// mode: 'wp',
// iconMode: 'ios',
// modalEnter: 'modal-slide-in',
// modalLeave: 'modal-slide-out',
// activator: 'highlight',
// pageTransition: 'wp-transition',
}),
ComponentsModule,
],
providers: [
StatusBar,
SplashScreen,
{ provide: ErrorHandler, useClass: IonicErrorHandler },
ElectronProvider,
StorageProvider,
UtilsProvider,
ConfigProvider
]
})
}));
示例8: beforeEach
beforeEach(async(() => {
statusBarSpy = jasmine.createSpyObj("StatusBar", ["styleDefault", "backgroundColorByHexString", "overlaysWebView"]);
splashScreenSpy = jasmine.createSpyObj("SplashScreen", ["hide"]);
platformReadySpy = Promise.resolve();
platformSpy = jasmine.createSpyObj("Platform", { ready: platformReadySpy });
TestBed.configureTestingModule({
imports: [
IonicStorageModule.forRoot(),
TranslateModule.forRoot(),
RouterTestingModule.withRoutes([])
],
declarations: [AppComponent],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
providers: [
HTTP,
Network,
{ provide: StatusBar, useValue: statusBarSpy },
{ provide: SplashScreen, useValue: splashScreenSpy },
{ provide: Platform, useValue: platformSpy }
]
}).compileComponents();
}));
示例9: beforeEach
beforeEach(() =>
TestBed.configureTestingModule({
imports: [IonicStorageModule.forRoot()],
providers: [HttpClient, HttpHandler, HTTP, Network]
})
示例10: beforeEach
beforeEach(() =>
TestBed.configureTestingModule({
imports: [IonicStorageModule.forRoot()]
})