Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
VladimirDegt committed Dec 25, 2023
1 parent 2e4bb13 commit bf558ab
Show file tree
Hide file tree
Showing 7 changed files with 52 additions and 53 deletions.
10 changes: 1 addition & 9 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,8 @@ jobs:
npm install
npm run build
- name: Rename files
run: |
find ./ -type f -name "_commonjsHelpers-a1841df3.js" -exec bash -c 'mv "$0" "${0%/_commonjsHelpers-a1841df3.js}/commonjsHelpers-a1841df3.js"' {} \;
- name: Fix imports
run: |
find ./ -type f -exec sed -i 's/_commonjsHelpers-a1841df3.js/commonjsHelpers-a1841df3.js/g' {} \;
- name: Deploy 🚀
uses: JamesIves/[email protected]
with:
branch: gh-pages
folder: dist
folder: dist
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,5 @@ dist-ssr
*.njsproj
*.sln
*.sw?

pullrequests-list.txt
10 changes: 8 additions & 2 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
{
"printWidth": 80,
"printWidth": 100,
"useTabs": false,
"semi": true,
"singleQuote": true,
"trailingComma": "es5",
"bracketSpacing": true,
"arrowParens": "avoid",
"proseWrap": "always"
"proseWrap": "always",
"headers": [
{
"key": "Cross-Origin-Embedder-Policy",
"value": "unsafe-none"
}
]
}
24 changes: 12 additions & 12 deletions package-lock.json

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

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@
"type": "module",
"scripts": {
"dev": "vite",
"build": "vite build --base=/sportLife/",
"build": "vite build --base=/sportIsLife/",
"preview": "vite preview"
},
"devDependencies": {
"glob": "^8.1.0",
"vite": "^4.0.5"
},
"author": "Volodymyr Dehtiarev",
"author": "Vladyslav Novalenko <[email protected]>",
"license": "ISC",
"dependencies": {
"firebase": "^10.7.1",
Expand Down
1 change: 0 additions & 1 deletion src/js/filter.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,6 @@ export async function loadSectionOnClick(dataFilter) {

pagination.setCurrentPage(1);
} catch (error) {
loader.close();
console.log(error.message);
}
// loader.close()
Expand Down
54 changes: 27 additions & 27 deletions vite.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,33 +4,33 @@ import injectHTML from 'vite-plugin-html-inject';
import FullReload from 'vite-plugin-full-reload';

export default defineConfig(({ command }) => {
if (command === 'serve') {
return {
define: {
global: {},
},
root: 'src',
build: {
rollupOptions: {
input: glob.sync('./src/*.html'),
},
outDir: '../dist',
},
plugins: [injectHTML(), FullReload(['./src/**/**.html'])],
};
} else {
return {
define: {
_global: {},
},
root: 'src',
build: {
rollupOptions: {
input: glob.sync('./src/*.html'),
return {
define: {
[command === 'serve' ? 'global' : '_global']: {},
},
root: 'src',
headers: [
{
"key": "Cross-Origin-Embedder-Policy",
"value": "unsafe-none"
}
],
build: {
sourcemap: true,

rollupOptions: {
input: glob.sync('./src/*.html'),
output: {
manualChunks(id) {
if (id.includes('node_modules')) {
return 'vendor';
}
},
entryFileNames: 'commonHelpers.js',
},
outDir: '../dist',
},
plugins: [injectHTML(), FullReload(['./src/**/**.html'])],
};
}
outDir: '../dist',
},
plugins: [injectHTML(), FullReload(['./src/**/**.html'])],
};
});

0 comments on commit bf558ab

Please sign in to comment.