Skip to content

Commit

Permalink
Merge pull request #10 from theolazian/fix-define-jquery
Browse files Browse the repository at this point in the history
Fix: define jquery
  • Loading branch information
aliceandbob-io committed Mar 13, 2022
2 parents 914363d + db4cca9 commit afbf4a2
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 2 deletions.
5 changes: 5 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "aliceandbob.io",
"productName": "aliceandbob.io",
"version": "1.0.0-Beta.2",
"version": "1.1.0-Beta.2",
"description": "A free, light and easy to use PGP tool based on OpenPGP.js.",
"main": "./.webpack/main",
"scripts": {
Expand Down Expand Up @@ -54,6 +54,7 @@
"dependencies": {
"@fortawesome/fontawesome-free": "^5.15.2",
"bootstrap": "^4.6.0",
"electron-squirrel-startup": "^1.0.0"
"electron-squirrel-startup": "^1.0.0",
"expose-loader": "^3.1.0"
}
}
2 changes: 2 additions & 0 deletions src/renderer.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
console.log('👋 This message is being logged by "renderer.js", included via webpack');

import $ from "jquery";

// Import Bootstrap and scss
import 'bootstrap';
import './scss/app.scss';
Expand Down
7 changes: 7 additions & 0 deletions webpack.rules.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,11 @@ module.exports = [
}
}
},
{
test: require.resolve("jquery"),
loader: "expose-loader",
options: {
exposes: ["$", "jQuery"]
},
},
];

0 comments on commit afbf4a2

Please sign in to comment.