Skip to content

Commit acf0af3

Browse files
committed
IBX-9109: Enabling TypeScript (ts-loader) with Webpack Encore
1 parent 3460a12 commit acf0af3

File tree

8 files changed

+37
-4
lines changed

8 files changed

+37
-4
lines changed

ibexa/commerce/5.0/encore/ibexa.webpack.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ module.exports = (Encore) => {
1616
'prop-types': 'PropTypes',
1717
})
1818
.enableSassLoader()
19+
.enableTypeScriptLoader()
1920
.enableReactPreset()
2021
.enableSingleRuntimeChunk();
2122

ibexa/commerce/5.0/encore/package.json

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,13 @@
2424
"@svgr/webpack": "^8.1.0"
2525
},
2626
"dependencies": {
27-
"react": "^18.2.0",
28-
"react-dom": "^18.2.0"
27+
"react": "^18.3.1",
28+
"react-dom": "^18.3.1",
29+
"@types/react": "^18.3.11",
30+
"@types/react-dom": "^18.3.1",
31+
"typescript": "^5.6.3",
32+
"ts-loader": "^9.5.1",
33+
"ts-config-ibexa": "https://github.com/ibexa/ts-config-ibexa"
2934
},
3035
"license": "UNLICENSED",
3136
"private": true,

ibexa/experience/5.0/encore/ibexa.webpack.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ module.exports = (Encore) => {
1616
'prop-types': 'PropTypes',
1717
})
1818
.enableSassLoader()
19+
.enableTypeScriptLoader()
1920
.enableReactPreset()
2021
.enableSingleRuntimeChunk();
2122

ibexa/experience/5.0/encore/package.json

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,16 @@
2222
"@ckeditor/ckeditor5-theme-lark": "^40.1.0",
2323
"@ckeditor/ckeditor5-code-block": "^40.1.0",
2424
"@svgr/webpack": "^8.1.0"
25+
2526
},
2627
"dependencies": {
27-
"react": "^18.2.0",
28-
"react-dom": "^18.2.0"
28+
"react": "^18.3.1",
29+
"react-dom": "^18.3.1",
30+
"@types/react": "^18.3.11",
31+
"@types/react-dom": "^18.3.1",
32+
"typescript": "^5.6.3",
33+
"ts-loader": "^9.5.1",
34+
"ts-config-ibexa": "https://github.com/ibexa/ts-config-ibexa"
2935
},
3036
"license": "UNLICENSED",
3137
"private": true,

ibexa/headless/5.0/encore/ibexa.webpack.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ module.exports = (Encore) => {
1616
'prop-types': 'PropTypes',
1717
})
1818
.enableSassLoader()
19+
.enableTypeScriptLoader()
1920
.enableReactPreset()
2021
.enableSingleRuntimeChunk();
2122

ibexa/headless/5.0/encore/package.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,15 @@
2323
"@ckeditor/ckeditor5-code-block": "^40.1.0",
2424
"@svgr/webpack": "^8.1.0"
2525
},
26+
"dependencies": {
27+
"react": "^18.3.1",
28+
"react-dom": "^18.3.1",
29+
"@types/react": "^18.3.11",
30+
"@types/react-dom": "^18.3.1",
31+
"typescript": "^5.6.3",
32+
"ts-loader": "^9.5.1",
33+
"ts-config-ibexa": "https://github.com/ibexa/ts-config-ibexa"
34+
},
2635
"license": "UNLICENSED",
2736
"private": true,
2837
"scripts": {

ibexa/oss/5.0/encore/ibexa.webpack.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ module.exports = (Encore) => {
1616
'prop-types': 'PropTypes',
1717
})
1818
.enableSassLoader()
19+
.enableTypeScriptLoader()
1920
.enableReactPreset()
2021
.enableSingleRuntimeChunk();
2122

ibexa/oss/5.0/encore/package.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,15 @@
2222
"@ckeditor/ckeditor5-code-block": "^40.1.0",
2323
"@svgr/webpack": "^8.1.0"
2424
},
25+
"dependencies": {
26+
"react": "^18.3.1",
27+
"react-dom": "^18.3.1",
28+
"@types/react": "^18.3.11",
29+
"@types/react-dom": "^18.3.1",
30+
"typescript": "^5.6.3",
31+
"ts-loader": "^9.5.1",
32+
"ts-config-ibexa": "https://github.com/ibexa/ts-config-ibexa"
33+
},
2534
"license": "UNLICENSED",
2635
"private": true,
2736
"scripts": {

0 commit comments

Comments
 (0)