当前位置: 首页>>代码示例>>TypeScript>>正文


TypeScript index.disableDeprecatedForms函数代码示例

本文整理汇总了TypeScript中@angular/forms/index.disableDeprecatedForms函数的典型用法代码示例。如果您正苦于以下问题:TypeScript disableDeprecatedForms函数的具体用法?TypeScript disableDeprecatedForms怎么用?TypeScript disableDeprecatedForms使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了disableDeprecatedForms函数的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。

示例1: beforeEach

    beforeEach(() => {
      providerArr = [disableDeprecatedForms(), provideForms()];

      let injector = ReflectiveInjector.resolveAndCreate([
        disableDeprecatedForms(),
        provideForms(),
        HTTP_PROVIDERS,
        NameListService,
        BaseRequestOptions,
        MockBackend,
        provide(Http, {
          useFactory: function(backend: ConnectionBackend, defaultOptions: BaseRequestOptions) {
            return new Http(backend, defaultOptions);
          },
          deps: [MockBackend, BaseRequestOptions]
        }),
      ]);
      nameListService = injector.get(NameListService);
      backend = injector.get(MockBackend);

      let connection: any;
      backend.connections.subscribe((c: any) => connection = c);
      initialResponse = nameListService.get();
      connection.mockRespond(new Response(new ResponseOptions({ body: '["Dijkstra", "Hopper"]' })));
    });
开发者ID:benetis,项目名称:color_picker,代码行数:25,代码来源:name-list.service.spec.ts

示例2: beforeEach

 beforeEach(() => { providerArr = [disableDeprecatedForms(), provideForms()]; });
开发者ID:martinsvb,项目名称:Angular2_bootstrap_seed,代码行数:1,代码来源:app.component.spec.ts

示例3: provideForms

t.be(() => { providerArr = [disableDeprecatedForms(), provideForms()]; });
开发者ID:BlackMr,项目名称:androidLauncher,代码行数:1,代码来源:support.component.spec.ts

示例4: bootstrap

import { HTTP_PROVIDERS } from '@angular/http';
import { bootstrap } from '@angular/platform-browser-dynamic';

import { APP_ROUTER_PROVIDERS } from './app.routes';
import { AppComponent } from './app.component';

import { MODAL_BROWSER_PROVIDERS } from 'angular2-modal/platform-browser/index'

if ('<%= ENV %>' === 'prod') { enableProdMode(); }

/**
 * Bootstraps the application and makes the ROUTER_PROVIDERS and the APP_BASE_HREF available to it.
 * @see https://angular.io/docs/ts/latest/api/platform-browser-dynamic/index/bootstrap-function.html
 */
bootstrap(AppComponent, [
  disableDeprecatedForms(),
  provideForms(),
  MODAL_BROWSER_PROVIDERS,
  HTTP_PROVIDERS,
  APP_ROUTER_PROVIDERS,
  {
    provide: APP_BASE_HREF,
    useValue: '<%= APP_BASE %>'
  }
]);

// In order to start the Service Worker located at "./worker.js"
// uncomment this line. More about Service Workers here
// https://developer.mozilla.org/en-US/docs/Web/API/Service_Worker_API/Using_Service_Workers
//
// if ('serviceWorker' in navigator) {
开发者ID:AntonFLB,项目名称:FoodDiary,代码行数:31,代码来源:main.ts


注:本文中的@angular/forms/index.disableDeprecatedForms函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。