mirror of
https://github.com/aspnet/JavaScriptServices.git
synced 2025-12-22 17:47:53 +00:00
Merge branch 'rel/2.0.0-templates' into dev
This commit is contained in:
@@ -5,13 +5,13 @@ import { enableProdMode } from '@angular/core';
|
||||
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
|
||||
import { AppModule } from './app/app.module.browser';
|
||||
|
||||
if (module['hot']) {
|
||||
module['hot'].accept();
|
||||
module['hot'].dispose(() => {
|
||||
if (module.hot) {
|
||||
module.hot.accept();
|
||||
module.hot.dispose(() => {
|
||||
// Before restarting the app, we create a new root element and dispose the old one
|
||||
const oldRootElem = document.querySelector('app');
|
||||
const newRootElem = document.createElement('app');
|
||||
oldRootElem.parentNode.insertBefore(newRootElem, oldRootElem);
|
||||
oldRootElem!.parentNode!.insertBefore(newRootElem, oldRootElem);
|
||||
modulePromise.then(appModule => appModule.destroy());
|
||||
});
|
||||
} else {
|
||||
|
||||
@@ -17,12 +17,12 @@ export default createServerRenderer(params => {
|
||||
];
|
||||
|
||||
return platformDynamicServer(providers).bootstrapModule(AppModule).then(moduleRef => {
|
||||
const appRef = moduleRef.injector.get(ApplicationRef);
|
||||
const appRef: ApplicationRef = moduleRef.injector.get(ApplicationRef);
|
||||
const state = moduleRef.injector.get(PlatformState);
|
||||
const zone = moduleRef.injector.get(NgZone);
|
||||
|
||||
return new Promise<RenderResult>((resolve, reject) => {
|
||||
zone.onError.subscribe(errorInfo => reject(errorInfo));
|
||||
zone.onError.subscribe((errorInfo: any) => reject(errorInfo));
|
||||
appRef.isStable.first(isStable => isStable).subscribe(() => {
|
||||
// Because 'onStable' fires before 'onError', we have to delay slightly before
|
||||
// completing the request in case there's an error to report
|
||||
|
||||
8
templates/AngularSpa/npm-shrinkwrap.json
generated
8
templates/AngularSpa/npm-shrinkwrap.json
generated
@@ -93,10 +93,10 @@
|
||||
"resolved": "https://registry.npmjs.org/@types/jasmine/-/jasmine-2.5.53.tgz",
|
||||
"dev": true
|
||||
},
|
||||
"@types/node": {
|
||||
"version": "8.0.8",
|
||||
"from": "@types/node@8.0.8",
|
||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-8.0.8.tgz"
|
||||
"@types/webpack-env": {
|
||||
"version": "1.13.0",
|
||||
"from": "@types/webpack-env@1.13.0",
|
||||
"resolved": "https://registry.npmjs.org/@types/webpack-env/-/webpack-env-1.13.0.tgz"
|
||||
},
|
||||
"accepts": {
|
||||
"version": "1.3.3",
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
"@angular/platform-server": "4.2.5",
|
||||
"@angular/router": "4.2.5",
|
||||
"@ngtools/webpack": "1.5.0",
|
||||
"@types/node": "8.0.8",
|
||||
"@types/webpack-env": "1.13.0",
|
||||
"angular2-template-loader": "0.6.2",
|
||||
"aspnet-prerendering": "^3.0.1",
|
||||
"aspnet-webpack": "^2.0.1",
|
||||
|
||||
@@ -1,13 +1,16 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "es2015",
|
||||
"moduleResolution": "node",
|
||||
"target": "es5",
|
||||
"sourceMap": true,
|
||||
"experimentalDecorators": true,
|
||||
"emitDecoratorMetadata": true,
|
||||
"skipDefaultLibCheck": true,
|
||||
"skipLibCheck": true, // Workaround for https://github.com/angular/angular/issues/17863. Remove this if you upgrade to a fixed version of Angular.
|
||||
"strict": true,
|
||||
"lib": [ "es6", "dom" ],
|
||||
"types": [ "node" ]
|
||||
"types": [ "webpack-env" ]
|
||||
},
|
||||
"exclude": [ "bin", "node_modules" ],
|
||||
"atom": { "rewriteTsconfig": false }
|
||||
|
||||
8
templates/AureliaSpa/npm-shrinkwrap.json
generated
8
templates/AureliaSpa/npm-shrinkwrap.json
generated
@@ -2,10 +2,10 @@
|
||||
"name": "WebApplicationBasic",
|
||||
"version": "0.0.0",
|
||||
"dependencies": {
|
||||
"@types/node": {
|
||||
"version": "7.0.32",
|
||||
"from": "@types/node@>=7.0.12 <8.0.0",
|
||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-7.0.32.tgz",
|
||||
"@types/webpack-env": {
|
||||
"version": "1.13.0",
|
||||
"from": "@types/webpack-env@>=1.13.0 <2.0.0",
|
||||
"resolved": "https://registry.npmjs.org/@types/webpack-env/-/webpack-env-1.13.0.tgz",
|
||||
"dev": true
|
||||
},
|
||||
"acorn": {
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
"jquery": "^3.2.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/node": "^7.0.12",
|
||||
"@types/webpack-env": "^1.13.0",
|
||||
"aspnet-webpack": "^2.0.1",
|
||||
"aurelia-webpack-plugin": "^2.0.0-rc.2",
|
||||
"css-loader": "^0.28.0",
|
||||
|
||||
@@ -1,13 +1,15 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "es2015",
|
||||
"moduleResolution": "node",
|
||||
"target": "es5",
|
||||
"sourceMap": true,
|
||||
"experimentalDecorators": true,
|
||||
"emitDecoratorMetadata": true,
|
||||
"skipDefaultLibCheck": true,
|
||||
"strict": true,
|
||||
"lib": [ "es2015", "dom" ],
|
||||
"types": [ "node" ]
|
||||
"types": [ "webpack-env" ]
|
||||
},
|
||||
"exclude": [ "bin", "node_modules" ],
|
||||
"atom": { "rewriteTsconfig": false }
|
||||
|
||||
@@ -1,21 +1,20 @@
|
||||
import './css/site.css';
|
||||
import 'bootstrap';
|
||||
import * as ko from 'knockout';
|
||||
import { createBrowserHistory } from 'history';
|
||||
import './webpack-component-loader';
|
||||
import AppRootComponent from './components/app-root/app-root';
|
||||
const createHistory = require('history').createBrowserHistory;
|
||||
const baseUrl = document.getElementsByTagName('base')[0].getAttribute('href');
|
||||
const baseUrl = document.getElementsByTagName('base')[0].getAttribute('href')!;
|
||||
const basename = baseUrl.substring(0, baseUrl.length - 1); // History component needs no trailing slash
|
||||
|
||||
// Load and register the <app-root> component
|
||||
ko.components.register('app-root', AppRootComponent);
|
||||
|
||||
// Tell Knockout to start up an instance of your application
|
||||
ko.applyBindings({ history: createHistory({ basename }), basename });
|
||||
ko.applyBindings({ history: createBrowserHistory({ basename }), basename });
|
||||
|
||||
// Basic hot reloading support. Automatically reloads and restarts the Knockout app each time
|
||||
// you modify source files. This will not preserve any application state other than the URL.
|
||||
declare var module: any;
|
||||
if (module.hot) {
|
||||
module.hot.accept();
|
||||
module.hot.dispose(() => ko.cleanNode(document.body));
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import * as ko from 'knockout';
|
||||
import * as $ from 'jquery';
|
||||
import * as History from 'history';
|
||||
import crossroads = require('crossroads');
|
||||
import * as crossroads from 'crossroads';
|
||||
|
||||
// This module configures crossroads.js, a routing library. If you prefer, you
|
||||
// can use any other routing library (or none at all) as Knockout is designed to
|
||||
@@ -20,9 +20,9 @@ export class Router {
|
||||
// Reset and configure Crossroads so it matches routes and updates this.currentRoute
|
||||
crossroads.removeAllRoutes();
|
||||
crossroads.resetState();
|
||||
crossroads.normalizeFn = crossroads.NORM_AS_OBJECT;
|
||||
(crossroads as any).normalizeFn = crossroads.NORM_AS_OBJECT;
|
||||
routes.forEach(route => {
|
||||
crossroads.addRoute(route.url, (requestParams) => {
|
||||
crossroads.addRoute(route.url, (requestParams: any) => {
|
||||
this.currentRoute(ko.utils.extend(requestParams, route.params));
|
||||
});
|
||||
});
|
||||
|
||||
@@ -8,18 +8,18 @@ ko.components.loaders.unshift({
|
||||
loadComponent: (name, componentConfig, callback) => {
|
||||
if (typeof componentConfig === 'function') {
|
||||
// It's a lazy-loaded Webpack bundle
|
||||
(componentConfig as any)(loadedModule => {
|
||||
(componentConfig as any)((loadedModule: any) => {
|
||||
// Handle TypeScript-style default exports
|
||||
if (loadedModule.__esModule && loadedModule.default) {
|
||||
loadedModule = loadedModule.default;
|
||||
}
|
||||
|
||||
// Pass the loaded module to KO's default loader
|
||||
ko.components.defaultLoader.loadComponent(name, loadedModule, callback);
|
||||
ko.components.defaultLoader.loadComponent!(name, loadedModule as KnockoutComponentTypes.ComponentConfig, callback);
|
||||
});
|
||||
} else {
|
||||
// It's something else - let another component loader handle it
|
||||
callback(null);
|
||||
callback((null as any) as KnockoutComponentTypes.Definition); // workaround until https://github.com/DefinitelyTyped/DefinitelyTyped/pull/17999
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
30
templates/KnockoutSpa/npm-shrinkwrap.json
generated
30
templates/KnockoutSpa/npm-shrinkwrap.json
generated
@@ -21,9 +21,9 @@
|
||||
"dev": true
|
||||
},
|
||||
"@types/history": {
|
||||
"version": "2.0.48",
|
||||
"from": "@types/history@>=2.0.38 <3.0.0",
|
||||
"resolved": "https://registry.npmjs.org/@types/history/-/history-2.0.48.tgz",
|
||||
"version": "4.6.0",
|
||||
"from": "@types/history@4.6.0",
|
||||
"resolved": "https://registry.npmjs.org/@types/history/-/history-4.6.0.tgz",
|
||||
"dev": true
|
||||
},
|
||||
"@types/jquery": {
|
||||
@@ -38,30 +38,18 @@
|
||||
"resolved": "https://registry.npmjs.org/@types/knockout/-/knockout-3.4.41.tgz",
|
||||
"dev": true
|
||||
},
|
||||
"@types/react": {
|
||||
"version": "15.0.31",
|
||||
"from": "@types/react@*",
|
||||
"resolved": "https://registry.npmjs.org/@types/react/-/react-15.0.31.tgz",
|
||||
"dev": true
|
||||
},
|
||||
"@types/react-router": {
|
||||
"version": "2.0.50",
|
||||
"from": "@types/react-router@>=2.0.37 <3.0.0",
|
||||
"resolved": "https://registry.npmjs.org/@types/react-router/-/react-router-2.0.50.tgz",
|
||||
"dev": true
|
||||
},
|
||||
"@types/requirejs": {
|
||||
"version": "2.1.29",
|
||||
"from": "@types/requirejs@>=2.1.26 <3.0.0",
|
||||
"resolved": "https://registry.npmjs.org/@types/requirejs/-/requirejs-2.1.29.tgz",
|
||||
"dev": true
|
||||
},
|
||||
"@types/signals": {
|
||||
"version": "0.0.16",
|
||||
"from": "@types/signals@0.0.16",
|
||||
"resolved": "https://registry.npmjs.org/@types/signals/-/signals-0.0.16.tgz",
|
||||
"dev": true
|
||||
},
|
||||
"@types/webpack-env": {
|
||||
"version": "1.13.0",
|
||||
"from": "@types/webpack-env@>=1.13.0 <2.0.0",
|
||||
"resolved": "https://registry.npmjs.org/@types/webpack-env/-/webpack-env-1.13.0.tgz",
|
||||
"dev": true
|
||||
},
|
||||
"acorn": {
|
||||
"version": "5.0.3",
|
||||
"from": "acorn@>=5.0.0 <6.0.0",
|
||||
|
||||
@@ -6,12 +6,11 @@
|
||||
"@types/core-js": "^0.9.34",
|
||||
"@types/crossroads": "0.0.29",
|
||||
"@types/es6-promise": "0.0.32",
|
||||
"@types/history": "^2.0.38",
|
||||
"@types/history": "^4.6.0",
|
||||
"@types/jquery": "^2.0.32",
|
||||
"@types/knockout": "^3.4.35",
|
||||
"@types/react-router": "^2.0.37",
|
||||
"@types/requirejs": "^2.1.26",
|
||||
"@types/knockout": "^3.4.41",
|
||||
"@types/signals": "0.0.16",
|
||||
"@types/webpack-env": "^1.13.0",
|
||||
"aspnet-webpack": "^2.0.1",
|
||||
"awesome-typescript-loader": "^3.0.0",
|
||||
"bootstrap": "^3.3.6",
|
||||
@@ -21,7 +20,7 @@
|
||||
"event-source-polyfill": "^0.0.7",
|
||||
"extract-text-webpack-plugin": "^2.0.0-rc",
|
||||
"file-loader": "^0.9.0",
|
||||
"history": "^4.3.0",
|
||||
"history": "^4.6.3",
|
||||
"isomorphic-fetch": "^2.2.1",
|
||||
"jquery": "^2.2.1",
|
||||
"json-loader": "^0.5.4",
|
||||
|
||||
@@ -1,10 +1,12 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "es2015",
|
||||
"moduleResolution": "node",
|
||||
"target": "es5",
|
||||
"sourceMap": true,
|
||||
"skipDefaultLibCheck": true,
|
||||
"types": ["es6-promise", "history", "requirejs"]
|
||||
"strict": true,
|
||||
"types": ["es6-promise", "webpack-env"]
|
||||
},
|
||||
"exclude": [
|
||||
"bin",
|
||||
|
||||
@@ -12,7 +12,7 @@ import * as RoutesModule from './routes';
|
||||
let routes = RoutesModule.routes;
|
||||
|
||||
// Create browser history to use in the Redux store
|
||||
const baseUrl = document.getElementsByTagName('base')[0].getAttribute('href');
|
||||
const baseUrl = document.getElementsByTagName('base')[0].getAttribute('href')!;
|
||||
const history = createBrowserHistory({ basename: baseUrl });
|
||||
|
||||
// Get the application-wide store instance, prepopulating with state from the server where available.
|
||||
|
||||
@@ -56,8 +56,8 @@ class FetchData extends React.Component<WeatherForecastProps, {}> {
|
||||
}
|
||||
|
||||
private renderPagination() {
|
||||
let prevStartDateIndex = this.props.startDateIndex - 5;
|
||||
let nextStartDateIndex = this.props.startDateIndex + 5;
|
||||
let prevStartDateIndex = (this.props.startDateIndex || 0) - 5;
|
||||
let nextStartDateIndex = (this.props.startDateIndex || 0) + 5;
|
||||
|
||||
return <p className='clearfix text-center'>
|
||||
<Link className='btn btn-default pull-left' to={ `/fetchdata/${ prevStartDateIndex }` }>Previous</Link>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { createStore, applyMiddleware, compose, combineReducers, GenericStoreEnhancer, Store } from 'redux';
|
||||
import { createStore, applyMiddleware, compose, combineReducers, GenericStoreEnhancer, Store, StoreEnhancerStoreCreator, ReducersMapObject } from 'redux';
|
||||
import thunk from 'redux-thunk';
|
||||
import { routerReducer, routerMiddleware } from 'react-router-redux';
|
||||
import * as StoreModule from './store';
|
||||
@@ -12,7 +12,7 @@ export default function configureStore(history: History, initialState?: Applicat
|
||||
const devToolsExtension = windowIfDefined && windowIfDefined.devToolsExtension as () => GenericStoreEnhancer;
|
||||
const createStoreWithMiddleware = compose(
|
||||
applyMiddleware(thunk, routerMiddleware(history)),
|
||||
devToolsExtension ? devToolsExtension() : f => f
|
||||
devToolsExtension ? devToolsExtension() : <S>(next: StoreEnhancerStoreCreator<S>) => next
|
||||
)(createStore);
|
||||
|
||||
// Combine all reducers and instantiate the app-wide store instance
|
||||
@@ -30,6 +30,6 @@ export default function configureStore(history: History, initialState?: Applicat
|
||||
return store;
|
||||
}
|
||||
|
||||
function buildRootReducer(allReducers) {
|
||||
function buildRootReducer(allReducers: ReducersMapObject) {
|
||||
return combineReducers<ApplicationState>(Object.assign({}, allReducers, { routing: routerReducer }));
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ import { AppThunkAction } from './';
|
||||
|
||||
export interface WeatherForecastsState {
|
||||
isLoading: boolean;
|
||||
startDateIndex: number;
|
||||
startDateIndex?: number;
|
||||
forecasts: WeatherForecast[];
|
||||
}
|
||||
|
||||
@@ -23,14 +23,14 @@ export interface WeatherForecast {
|
||||
// They do not themselves have any side-effects; they just describe something that is going to happen.
|
||||
|
||||
interface RequestWeatherForecastsAction {
|
||||
type: 'REQUEST_WEATHER_FORECASTS',
|
||||
type: 'REQUEST_WEATHER_FORECASTS';
|
||||
startDateIndex: number;
|
||||
}
|
||||
|
||||
interface ReceiveWeatherForecastsAction {
|
||||
type: 'RECEIVE_WEATHER_FORECASTS',
|
||||
type: 'RECEIVE_WEATHER_FORECASTS';
|
||||
startDateIndex: number;
|
||||
forecasts: WeatherForecast[]
|
||||
forecasts: WeatherForecast[];
|
||||
}
|
||||
|
||||
// Declare a 'discriminated union' type. This guarantees that all references to 'type' properties contain one of the
|
||||
@@ -60,7 +60,7 @@ export const actionCreators = {
|
||||
// ----------------
|
||||
// REDUCER - For a given state and action, returns the new state. To support time travel, this must not mutate the old state.
|
||||
|
||||
const unloadedState: WeatherForecastsState = { startDateIndex: null, forecasts: [], isLoading: false };
|
||||
const unloadedState: WeatherForecastsState = { forecasts: [], isLoading: false };
|
||||
|
||||
export const reducer: Reducer<WeatherForecastsState> = (state: WeatherForecastsState, incomingAction: Action) => {
|
||||
const action = incomingAction as KnownAction;
|
||||
|
||||
@@ -3,8 +3,8 @@ import * as Counter from './Counter';
|
||||
|
||||
// The top-level state object
|
||||
export interface ApplicationState {
|
||||
counter: Counter.CounterState,
|
||||
weatherForecasts: WeatherForecasts.WeatherForecastsState
|
||||
counter: Counter.CounterState;
|
||||
weatherForecasts: WeatherForecasts.WeatherForecastsState;
|
||||
}
|
||||
|
||||
// Whenever an action is dispatched, Redux will update each top-level application state property using
|
||||
|
||||
5
templates/ReactReduxSpa/npm-shrinkwrap.json
generated
5
templates/ReactReduxSpa/npm-shrinkwrap.json
generated
@@ -22,6 +22,11 @@
|
||||
"from": "@types/react-dom@15.5.1",
|
||||
"resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-15.5.1.tgz"
|
||||
},
|
||||
"@types/react-hot-loader": {
|
||||
"version": "3.0.3",
|
||||
"from": "@types/react-hot-loader@3.0.3",
|
||||
"resolved": "https://registry.npmjs.org/@types/react-hot-loader/-/react-hot-loader-3.0.3.tgz"
|
||||
},
|
||||
"@types/react-redux": {
|
||||
"version": "4.4.45",
|
||||
"from": "@types/react-redux@4.4.45",
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
"@types/history": "4.6.0",
|
||||
"@types/react": "15.0.35",
|
||||
"@types/react-dom": "15.5.1",
|
||||
"@types/react-hot-loader": "3.0.3",
|
||||
"@types/react-redux": "4.4.45",
|
||||
"@types/react-router": "4.0.12",
|
||||
"@types/react-router-dom": "4.0.5",
|
||||
|
||||
@@ -1,21 +1,16 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"baseUrl": ".",
|
||||
"module": "es2015",
|
||||
"moduleResolution": "node",
|
||||
"target": "es5",
|
||||
"jsx": "react",
|
||||
"experimentalDecorators": true,
|
||||
"sourceMap": true,
|
||||
"skipDefaultLibCheck": true,
|
||||
"strict": true,
|
||||
"lib": ["es6", "dom"],
|
||||
"types": [ "webpack-env" ],
|
||||
"paths": {
|
||||
// Fix "Duplicate identifier" errors caused by multiple dependencies fetching their own copies of type definitions.
|
||||
// We tell TypeScript which type definitions module to treat as the canonical one (instead of combining all of them).
|
||||
"history": ["./node_modules/@types/history/index"],
|
||||
"redux": ["./node_modules/@types/redux/index"],
|
||||
"react": ["./node_modules/@types/react/index"]
|
||||
}
|
||||
"types": ["webpack-env"]
|
||||
},
|
||||
"exclude": [
|
||||
"bin",
|
||||
|
||||
@@ -10,7 +10,7 @@ let routes = RoutesModule.routes;
|
||||
function renderApp() {
|
||||
// This code starts up the React app when it runs in a browser. It sets up the routing
|
||||
// configuration and injects the app into a DOM element.
|
||||
const baseUrl = document.getElementsByTagName('base')[0].getAttribute('href');
|
||||
const baseUrl = document.getElementsByTagName('base')[0].getAttribute('href')!;
|
||||
ReactDOM.render(
|
||||
<AppContainer>
|
||||
<BrowserRouter children={ routes } basename={ baseUrl } />
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
import * as React from 'react';
|
||||
import { RouteComponentProps } from 'react-router';
|
||||
|
||||
interface CounterState {
|
||||
currentCount: number;
|
||||
}
|
||||
|
||||
export class Counter extends React.Component<{}, CounterState> {
|
||||
export class Counter extends React.Component<RouteComponentProps<{}>, CounterState> {
|
||||
constructor() {
|
||||
super();
|
||||
this.state = { currentCount: 0 };
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import * as React from 'react';
|
||||
import { RouteComponentProps } from 'react-router';
|
||||
import 'isomorphic-fetch';
|
||||
|
||||
interface FetchDataExampleState {
|
||||
@@ -6,7 +7,7 @@ interface FetchDataExampleState {
|
||||
loading: boolean;
|
||||
}
|
||||
|
||||
export class FetchData extends React.Component<{}, FetchDataExampleState> {
|
||||
export class FetchData extends React.Component<RouteComponentProps<{}>, FetchDataExampleState> {
|
||||
constructor() {
|
||||
super();
|
||||
this.state = { forecasts: [], loading: true };
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import * as React from 'react';
|
||||
import { RouteComponentProps } from 'react-router';
|
||||
|
||||
export class Home extends React.Component<{}, {}> {
|
||||
export class Home extends React.Component<RouteComponentProps<{}>, {}> {
|
||||
public render() {
|
||||
return <div>
|
||||
<h1>Hello, world!</h1>
|
||||
|
||||
12
templates/ReactSpa/npm-shrinkwrap.json
generated
12
templates/ReactSpa/npm-shrinkwrap.json
generated
@@ -20,12 +20,24 @@
|
||||
"resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-15.5.1.tgz",
|
||||
"dev": true
|
||||
},
|
||||
"@types/react-hot-loader": {
|
||||
"version": "3.0.3",
|
||||
"from": "@types/react-hot-loader@3.0.3",
|
||||
"resolved": "https://registry.npmjs.org/@types/react-hot-loader/-/react-hot-loader-3.0.3.tgz",
|
||||
"dev": true
|
||||
},
|
||||
"@types/react-router": {
|
||||
"version": "4.0.12",
|
||||
"from": "@types/react-router@4.0.12",
|
||||
"resolved": "https://registry.npmjs.org/@types/react-router/-/react-router-4.0.12.tgz",
|
||||
"dev": true
|
||||
},
|
||||
"@types/react-router-dom": {
|
||||
"version": "4.0.5",
|
||||
"from": "@types/react-router-dom@4.0.5",
|
||||
"resolved": "https://registry.npmjs.org/@types/react-router-dom/-/react-router-dom-4.0.5.tgz",
|
||||
"dev": true
|
||||
},
|
||||
"@types/webpack-env": {
|
||||
"version": "1.13.0",
|
||||
"from": "@types/webpack-env@1.13.0",
|
||||
|
||||
@@ -6,7 +6,9 @@
|
||||
"@types/history": "4.6.0",
|
||||
"@types/react": "15.0.35",
|
||||
"@types/react-dom": "15.5.1",
|
||||
"@types/react-hot-loader": "3.0.3",
|
||||
"@types/react-router": "4.0.12",
|
||||
"@types/react-router-dom": "4.0.5",
|
||||
"@types/webpack-env": "1.13.0",
|
||||
"aspnet-webpack": "^2.0.1",
|
||||
"aspnet-webpack-react": "^3.0.0",
|
||||
|
||||
@@ -1,18 +1,14 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"baseUrl": ".",
|
||||
"module": "es2015",
|
||||
"moduleResolution": "node",
|
||||
"target": "es5",
|
||||
"jsx": "react",
|
||||
"sourceMap": true,
|
||||
"skipDefaultLibCheck": true,
|
||||
"types": [ "webpack-env" ],
|
||||
"paths": {
|
||||
// Fix "Duplicate identifier" errors caused by multiple dependencies fetching their own copies of type definitions.
|
||||
// We tell TypeScript which type definitions module to treat as the canonical one (instead of combining all of them).
|
||||
"history": ["./node_modules/@types/history/index"],
|
||||
"react": ["./node_modules/@types/react/index"]
|
||||
}
|
||||
"strict": true,
|
||||
"types": ["webpack-env"]
|
||||
},
|
||||
"exclude": [
|
||||
"bin",
|
||||
|
||||
8
templates/VueSpa/npm-shrinkwrap.json
generated
8
templates/VueSpa/npm-shrinkwrap.json
generated
@@ -2,10 +2,10 @@
|
||||
"name": "WebApplicationBasic",
|
||||
"version": "0.0.0",
|
||||
"dependencies": {
|
||||
"@types/requirejs": {
|
||||
"version": "2.1.29",
|
||||
"from": "@types/requirejs@>=2.1.28 <3.0.0",
|
||||
"resolved": "https://registry.npmjs.org/@types/requirejs/-/requirejs-2.1.29.tgz",
|
||||
"@types/webpack-env": {
|
||||
"version": "1.13.0",
|
||||
"from": "@types/webpack-env@>=1.13.0 <2.0.0",
|
||||
"resolved": "https://registry.npmjs.org/@types/webpack-env/-/webpack-env-1.13.0.tgz",
|
||||
"dev": true
|
||||
},
|
||||
"abbrev": {
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
"private": true,
|
||||
"version": "0.0.0",
|
||||
"devDependencies": {
|
||||
"@types/requirejs": "^2.1.28",
|
||||
"@types/webpack-env": "^1.13.0",
|
||||
"aspnet-webpack": "^2.0.1",
|
||||
"awesome-typescript-loader": "^3.0.0",
|
||||
"bootstrap": "^3.3.6",
|
||||
|
||||
@@ -7,7 +7,8 @@
|
||||
"target": "es5",
|
||||
"sourceMap": true,
|
||||
"skipDefaultLibCheck": true,
|
||||
"types": ["requirejs"]
|
||||
"strict": true,
|
||||
"types": ["webpack-env"]
|
||||
},
|
||||
"exclude": [
|
||||
"bin",
|
||||
|
||||
Reference in New Issue
Block a user