Skip to content

Commit

Permalink
updated deps and converted more tests to TSX for github#1632
Browse files Browse the repository at this point in the history
  • Loading branch information
Havunen committed Apr 13, 2024
1 parent 527f088 commit 7ea5df9
Show file tree
Hide file tree
Showing 7 changed files with 2,516 additions and 2,315 deletions.
2,036 changes: 1,212 additions & 824 deletions fixtures/browser/package-lock.json

Large diffs are not rendered by default.

16 changes: 8 additions & 8 deletions fixtures/browser/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,21 +19,21 @@
"author": "",
"license": "MIT",
"dependencies": {
"@babel/core": "7.23.7",
"@babel/preset-env": "7.23.8",
"@babel/core": "7.24.4",
"@babel/preset-env": "7.24.4",
"babel-loader": "^9.1.3",
"build-time-reporter-webpack-plugin": "^1.4.3",
"jasmine-core": "^5.1.1",
"karma": "^6.4.2",
"jasmine-core": "^5.1.2",
"karma": "^6.4.3",
"karma-chrome-launcher": "^3.2.0",
"karma-detect-browsers": "^2.3.3",
"karma-firefox-launcher": "^2.1.2",
"karma-firefox-launcher": "^2.1.3",
"karma-jasmine": "^5.1.0",
"havunen-karma-sauce-launcher2": "^5.0.7",
"karma-webpack": "5.0.0",
"karma-webpack": "5.0.1",
"output-compile-time-webpack-plugin": "^1.0.5",
"saucelabs": "7.4.0",
"saucelabs": "7.5.0",
"ts-loader": "^9.5.1",
"webpack": "^5.89.0"
"webpack": "^5.91.0"
}
}
2,725 changes: 1,266 additions & 1,459 deletions package-lock.json

Large diffs are not rendered by default.

30 changes: 15 additions & 15 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -81,38 +81,38 @@
"test:memory:js-framework:debug": "node --inspect-brk --expose-gc scripts/fakedom/js-framework-bench/start.js"
},
"devDependencies": {
"@babel/core": "^7.24.0",
"@babel/core": "^7.24.4",
"@babel/plugin-proposal-class-properties": "7.18.6",
"@babel/plugin-transform-modules-commonjs": "^7.23.3",
"@babel/preset-env": "7.24.0",
"@babel/preset-typescript": "^7.23.3",
"@babel/plugin-transform-modules-commonjs": "^7.24.1",
"@babel/preset-env": "7.24.4",
"@babel/preset-typescript": "^7.24.1",
"@rollup/plugin-alias": "^5.1.0",
"@rollup/plugin-babel": "^6.0.4",
"@rollup/plugin-commonjs": "^25.0.7",
"@rollup/plugin-json": "^6.1.0",
"@rollup/plugin-node-resolve": "^15.2.3",
"@rollup/plugin-replace": "^5.0.5",
"@rollup/plugin-terser": "^0.4.4",
"@swc/core": "^1.4.2",
"@swc/core": "^1.4.13",
"@swc/jest": "^0.2.36",
"@types/jest": "^29.5.12",
"@types/jsdom": "^21.1.6",
"@types/node": "^20.11.24",
"@typescript-eslint/eslint-plugin": "^6.21.0",
"@types/node": "^20.12.7",
"@typescript-eslint/eslint-plugin": "^7.6.0",
"babel-plugin-inferno": "6.7.1",
"cli-table": "^0.3.11",
"concat-stream": "^2.0.0",
"coveralls-next": "^4.2.0",
"coveralls-next": "^4.2.1",
"cross-env": "^7.0.3",
"d3-scale-chromatic": "^3.0.0",
"d3-scale-chromatic": "^3.1.0",
"eslint": "^8.57.0",
"eslint-config-prettier": "^9.1.0",
"eslint-config-standard-with-typescript": "^43.0.1",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-n": "^16.6.2",
"eslint-plugin-n": "^17.2.0",
"eslint-plugin-prettier": "^5.1.3",
"eslint-plugin-promise": "^6.1.1",
"filesize": "^10.1.0",
"filesize": "^10.1.1",
"fs-extra": "^11.2.0",
"gzip-size": "^7.0.0",
"history": "^5.3.0",
Expand All @@ -124,17 +124,17 @@
"lerna": "^8",
"lint-staged": "^15.2.2",
"minimist": "^1.2.8",
"mobx": "^6.12.0",
"mobx": "^6.12.3",
"npm-run-all": "^4.1.5",
"perf-monitor": "^0.6.0",
"pre-commit": "^1.2.2",
"prettier": "^3.2.5",
"rimraf": "^5",
"rollup": "^4.12.0",
"rollup": "^4.14.2",
"swc": "^1.0.11",
"swc-loader": "^0.2.6",
"swc-plugin-inferno": "^0.0.19",
"swc-plugin-inferno": "^0.0.20",
"ts-plugin-inferno": "^6.0.3",
"typescript": "^5.3.3"
"typescript": "^5.4.5"
}
}
2 changes: 1 addition & 1 deletion packages/inferno-redux/src/components/connectAdvanced.ts
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ export function connectAdvanced(
}

public isSubscribed(): boolean {
return Boolean(this.subscription && this.subscription.isSubscribed());
return Boolean(this.subscription?.isSubscribed());
}

// eslint-disable-next-line @typescript-eslint/explicit-function-return-type
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,11 @@ describe('SSR render() arguments', () => {
}

it('should have props as 1st argument', () => {
class TestChild extends Component {
interface TestChildProps {
testProps: string
}

class TestChild extends Component<TestChildProps> {
render(props) {
return <p>{props.testProps}</p>;
}
Expand All @@ -25,12 +29,13 @@ describe('SSR render() arguments', () => {

it('should have state as 2nd argument', () => {
class TestChild extends Component {

constructor() {
super();
this.state = { testState: 'state-works' };
}

render(props, state) {
render(_props, state) {
return <p>{state.testState}</p>;
}
}
Expand All @@ -40,7 +45,7 @@ describe('SSR render() arguments', () => {

it('statefull has context as 3rd argument', () => {
class TestChild extends Component {
render(props, state, context) {
render(_props, _state, context) {
return <p>{context.testContext}</p>;
}
}
Expand All @@ -54,7 +59,7 @@ describe('SSR render() arguments', () => {
});

it('stateless has context as 2nd argument', () => {
function TestChild(props, context) {
function TestChild(_props, context) {
return <p>{context.testContext}</p>;
}

Expand All @@ -67,10 +72,11 @@ describe('SSR render() arguments', () => {
});

it('nested stateless has context as 2nd argument', () => {
function ChildWrapper(props, context) {

function ChildWrapper(props) {
return props.children;
}
function TestChild(props, context) {
function TestChild(_props, context) {
return <p>{context.testContext}</p>;
}
const output = renderToStaticMarkup(
Expand All @@ -95,7 +101,7 @@ describe('SSR render() arguments', () => {
return children;
}
}
function TestChild(props, context) {
function TestChild(_props: unknown, context) {
return (
<p>
{context.testContext}|{context.testContextWrap}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ describe('Security - SSR', () => {
});

async function streamPromise(dom, method) {
return await new Promise(function (res, rej) {
return await new Promise(function (res: (value: string) => void, rej) {
method(dom)
.on('error', rej)
.pipe(
Expand Down

0 comments on commit 7ea5df9

Please sign in to comment.