Skip to content

Commit

Permalink
[#1634] Replace cdn links to import from node_modules instead (#1710)
Browse files Browse the repository at this point in the history
Some css files are currently imported directly in the code, making it
difficult to manage.

Let us import from node_module for easy management.
  • Loading branch information
zhoukerrr committed Mar 17, 2022
1 parent fb0afca commit a4ee187
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
3 changes: 3 additions & 0 deletions frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
},
"homepage": "https://github.com/reposense/RepoSense#readme",
"dependencies": {
"@fontsource/titillium-web": "^4.5.3",
"@fortawesome/fontawesome-svg-core": "^1.3.0",
"@fortawesome/free-brands-svg-icons": "^6.0.0",
"@fortawesome/free-solid-svg-icons": "^6.0.0",
Expand All @@ -34,6 +35,8 @@
"highlight.js": "^10.5.0",
"jszip": "^3.5.0",
"minimatch": "^3.0.4",
"muicss": "^0.10.3",
"normalize.css": "^8.0.1",
"pug-lint-vue": "^0.4.0",
"seedrandom": "^3.0.5",
"vue": "^3.2.31",
Expand Down
6 changes: 0 additions & 6 deletions frontend/src/app.vue
Original file line number Diff line number Diff line change
Expand Up @@ -319,12 +319,6 @@ export default app;


<style lang="scss">
@import 'https://fonts.googleapis.com/css?family=Titillium+Web';
@import 'https://cdn.jsdelivr.net/npm/normalize.css@8.0/normalize.min.css';
@import 'https://cdn.jsdelivr.net/npm/muicss@0.9/dist/css/mui.min.css';
@import 'https://cdn.jsdelivr.net/npm/highlight.js@9.14/styles/color-brewer.min.css';
@import 'https://cdn.jsdelivr.net/npm/vue-loading-overlay@5/dist/vue-loading.css';
@import './styles/style.scss';
@import './styles/panels.scss';
</style>
5 changes: 5 additions & 0 deletions frontend/src/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@ import { createApp } from 'vue';
import { dom } from '@fortawesome/fontawesome-svg-core';
import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome';
import hljs from 'highlight.js';
import 'muicss/dist/css/mui.min.css';
import 'normalize.css/normalize.css';
import 'vue-loading-overlay/dist/vue-loading.css';
import 'highlight.js/styles/color-brewer.css';
import '@fontsource/titillium-web';

// Need to import for side effects
import './utils/api';
Expand Down

0 comments on commit a4ee187

Please sign in to comment.