Skip to content

Commit 9d4f279

Browse files
committed
chore: Updates to handle upgraded dependencies.
1 parent f57c5c4 commit 9d4f279

File tree

8 files changed

+2751
-2976
lines changed

8 files changed

+2751
-2976
lines changed

package.json

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
"toc": "markdown-toc -i --maxdepth 2 README.md",
88
"compile": "tsc -b packages",
99
"compile:watch": "tsc -b packages --watch",
10+
"test": "lerna run test",
1011
"test:all": "lerna run test:runner",
1112
"compile:clean": "rm -rf packages/@css-blocks/*/dist && yarn run compile",
1213
"install:clean": "rm -rf node_modules packages/@css-blocks/*/node_modules && yarn"

packages/@css-blocks/broccoli/tsconfig.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
{
22
"extends": "../../../tsconfig.json",
33
"compilerOptions": {
4-
"composite": true,
4+
// Composite is false due to https://github.com/Microsoft/TypeScript/issues/31181
5+
"composite": false,
56
"outDir": "dist",
67
"baseUrl": "dist"
78
},

packages/@css-blocks/core/src/Analyzer/validations/property-conflict-validator.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,8 @@ function formatRulesetConflicts(prop: string, rules: Ruleset<Style>[]) {
131131
let decl = rule.declarations.get(prop);
132132
let nodes: postcss.Rule[] | postcss.Declaration[] = decl ? decl.map((d) => d.node) : [rule.node];
133133
for (let node of nodes) {
134-
let line = node.source.start && `:${node.source.start.line}` || "";
135-
let column = node.source.start && `:${node.source.start.column}` || "";
134+
let line = node.source && node.source.start && `:${node.source.start.line}` || "";
135+
let column = node.source && node.source.start && `:${node.source.start.column}` || "";
136136
out.add(` ${rule.style.asSource(true)} (${rule.file}${line}${column})`);
137137
}
138138
}

packages/@css-blocks/webpack/package.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,10 @@
4444
"@types/convert-source-map": "^1.3.33",
4545
"@types/extract-text-webpack-plugin": "^2.1.0",
4646
"@types/glob": "^7.1.1",
47+
"@types/tapable": "^0.2.4",
4748
"@types/webpack": "^4.0.0",
4849
"@types/webpack-merge": "4.1.5",
49-
"@types/webpack-sources": "^0.1.2",
50+
"@types/webpack-sources": "^0.1.5",
5051
"css-loader": "^0.28.4",
5152
"extract-text-webpack-plugin": "^2.1.2",
5253
"glob": "^7.1.2",
@@ -69,4 +70,4 @@
6970
"tapable": "^0.2.5",
7071
"webpack-sources": "^1.0.1"
7172
}
72-
}
73+
}

packages/@css-blocks/webpack/test/configs/basicConfig.ts

+4-1
Original file line numberDiff line numberDiff line change
@@ -36,5 +36,8 @@ export function config(entry: EntryTypes, options?: LoaderOptions): WebpackConfi
3636
}),
3737
],
3838
};
39-
return merge(defaultOutputConfig(), baseConfig);
39+
40+
// The webpack types used by webpack-merge don't agree with ours.
41+
// tslint:disable-next-line:prefer-unknown-to-any
42+
return merge(defaultOutputConfig() as any, baseConfig as any) as any;
4043
}

packages/@css-blocks/webpack/test/configs/extractTextConfig.ts

+7-2
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@ export function config(entry: string, options?: LoaderOptions): WebpackConfigura
1414
filename: "[name].[contenthash].css",
1515
});
1616

17-
return merge(defaultOutputConfig(), {
17+
let outputConfig = defaultOutputConfig();
18+
let config = {
1819
entry: entry,
1920
output: {
2021
filename: "bundle.extractText.js",
@@ -36,5 +37,9 @@ export function config(entry: string, options?: LoaderOptions): WebpackConfigura
3637
plugins: [
3738
extractText,
3839
],
39-
});
40+
};
41+
42+
// The webpack types used by webpack-merge don't agree with ours.
43+
// tslint:disable-next-line:prefer-unknown-to-any
44+
return merge(outputConfig as any, config as any) as any;
4045
}

packages/@css-blocks/webpack/test/configs/templateConfig.ts

+6-2
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ export function config(): Promise<WebpackConfiguration> {
7373
analyzer,
7474
});
7575

76-
return merge(defaultOutputConfig(), {
76+
let config = {
7777
entry: "./test/fixtures/javascripts/foo.js",
7878
output: {
7979
filename: "bundle.template.js",
@@ -94,6 +94,10 @@ export function config(): Promise<WebpackConfiguration> {
9494
inlineSourceMaps: false,
9595
}),
9696
],
97-
});
97+
};
98+
99+
// The webpack types used by webpack-merge don't agree with ours.
100+
// tslint:disable-next-line:prefer-unknown-to-any
101+
return merge(defaultOutputConfig() as any, config as any) as any;
98102
});
99103
}

0 commit comments

Comments
 (0)