Skip to content

Commit 3139c2c

Browse files
committed
Attempt to fix build/deployment on github actions
Although `yarn build` worked locally it appears that this is only because of the availability of installed packages in the parent directory. Running `yarn build` on GitHub CI fails because these packages aren't yet available. We've specified the versions of the packages that we need by copying the versions from package.json in the RPI fork of scratch-gui[1]. This is because our scratch/src/index.jsx file is essentially a modified version of a combination of scratch-gui/src/playground/index.jsx and render-gui.jsx so we think it makes sense to use the same versions of the third party libraries. We change the babel react preset for the same reason. [1]: https://github.com/RaspberryPiFoundation/scratch-gui/blob/code-club-world/package.json
1 parent 1c9717b commit 3139c2c

File tree

3 files changed

+235
-13
lines changed

3 files changed

+235
-13
lines changed

scratch/.babelrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
22
"presets": [
3-
"react-app",
3+
"@babel/preset-react",
44
]
55
}

scratch/package.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,16 @@
1010
},
1111
"dependencies": {
1212
"@raspberrypifoundation/scratch-gui": "0.1.0-raspberrypifoundation.20230606092831",
13+
"react": "16.2.0",
14+
"react-dom": "16.2.1",
15+
"redux": "3.7.2",
1316
"scratch-gui": "^5.1.27"
1417
},
1518
"devDependencies": {
19+
"@babel/core": "7.14.8",
20+
"@babel/preset-react": "7.14.5",
1621
"@webpack-cli/generators": "^3.0.7",
22+
"babel-loader": "8.2.2",
1723
"webpack": "^5.97.1",
1824
"webpack-cli": "^6.0.1"
1925
},

0 commit comments

Comments
 (0)