Skip to content

Commit 54f222e

Browse files
Update templates for Yarn compatibility
1 parent 6259b7b commit 54f222e

File tree

11 files changed

+20
-2
lines changed

11 files changed

+20
-2
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,4 +37,5 @@ npm-debug.log
3737
/templates/*/node_modules/
3838
/templates/*/wwwroot/dist/
3939
/templates/*/ClientApp/dist/
40+
/templates/*/yarn.lock
4041
.vscode/

templates/Angular2Spa/template_gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -196,6 +196,8 @@ orleans.codegen.cs
196196
/node_modules/**
197197
!/node_modules/_placeholder.txt
198198

199+
/yarn.lock
200+
199201
# RIA/Silverlight projects
200202
Generated_Code/
201203

templates/AureliaSpa/template_gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ Obj/
3535
!/wwwroot/dist/_placeholder.txt
3636
!/ClientApp/dist/_placeholder.txt
3737

38+
/yarn.lock
3839

3940
# MSTest test Results
4041
[Tt]est[Rr]esult*/

templates/KnockoutSpa/ClientApp/components/app-root/app-root.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import * as ko from 'knockout';
2+
import * as History from 'history';
23
import { Route, Router } from '../../router';
34
import navMenu from '../nav-menu/nav-menu';
45

templates/KnockoutSpa/ClientApp/router.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import * as ko from 'knockout';
22
import * as $ from 'jquery';
3+
import * as History from 'history';
34
import crossroads = require('crossroads');
45

56
// This module configures crossroads.js, a routing library. If you prefer, you

templates/KnockoutSpa/template_gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ Obj/
3333
# Workaround for https://github.com/aspnet/JavaScriptServices/issues/235
3434
!/wwwroot/dist/_placeholder.txt
3535

36+
/yarn.lock
37+
3638
# MSTest test Results
3739
[Tt]est[Rr]esult*/
3840
[Bb]uild[Ll]og.*

templates/ReactReduxSpa/template_gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ Obj/
3535
!/wwwroot/dist/_placeholder.txt
3636
!/ClientApp/dist/_placeholder.txt
3737

38+
/yarn.lock
3839

3940
# MSTest test Results
4041
[Tt]est[Rr]esult*/

templates/ReactReduxSpa/tsconfig.json

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,18 @@
11
{
22
"compilerOptions": {
3+
"baseUrl": ".",
34
"moduleResolution": "node",
45
"target": "es6",
56
"jsx": "preserve",
67
"experimentalDecorators": true,
78
"sourceMap": true,
89
"skipDefaultLibCheck": true,
910
"lib": ["es6", "dom"],
10-
"types": [ "webpack-env", "whatwg-fetch" ]
11+
"types": [ "webpack-env", "whatwg-fetch" ],
12+
"paths": {
13+
// Fixes "Duplicate identifier 'Redux'" error when packages were installed via Yarn (by specifying which .d.ts file is authoritative)
14+
"redux": ["./node_modules/@types/redux/index"]
15+
}
1116
},
1217
"exclude": [
1318
"bin",

templates/ReactSpa/template_gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ Obj/
3333
# Workaround for https://github.com/aspnet/JavaScriptServices/issues/235
3434
!/wwwroot/dist/_placeholder.txt
3535

36+
/yarn.lock
37+
3638
# MSTest test Results
3739
[Tt]est[Rr]esult*/
3840
[Bb]uild[Ll]og.*

templates/WebApplicationBasic/template_gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ Obj/
3030
.vs/
3131
/wwwroot/dist/
3232

33+
/yarn.lock
34+
3335
# MSTest test Results
3436
[Tt]est[Rr]esult*/
3537
[Bb]uild[Ll]og.*

0 commit comments

Comments
 (0)