-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Inertia v1.2.0
- Loading branch information
Showing
70 changed files
with
4,270 additions
and
7,601 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
src/config/config.js | ||
src/config/config.js | ||
public/uv |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
extends: | ||
- eslint:recommended | ||
- next/core-web-vitals | ||
|
||
plugins: | ||
- react | ||
- import | ||
- simple-import-sort | ||
|
||
env: | ||
browser: true | ||
es2021: true | ||
node: true | ||
|
||
rules: | ||
indent: | ||
- warn | ||
- tab | ||
|
||
quotes: | ||
- warn | ||
- single | ||
|
||
semi: | ||
- error | ||
- always | ||
|
||
no-unused-vars: off | ||
no-undef: off | ||
no-constant-condition: off | ||
no-self-assign: off | ||
no-empty: off | ||
|
||
react/jsx-sort-props: | ||
- warn | ||
- shorthandLast: true | ||
noSortAlphabetically: false | ||
reservedFirst: true | ||
|
||
import/first: warn | ||
import/exports-last: warn | ||
import/no-duplicates: warn | ||
import/no-unresolved: off | ||
|
||
import/newline-after-import: | ||
- warn | ||
- count: 2 | ||
|
||
sort-imports: | ||
- warn | ||
- allowSeparatedGroups: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
const exec = require('child_process').exec; | ||
const provider = process.argv[2]; | ||
|
||
const defaultHandler = (err, stdout, stderr) => { | ||
if (err) { | ||
console.error(err); | ||
return; | ||
} | ||
console.log(stdout); | ||
console.log(stderr); | ||
}; | ||
|
||
const fs = require('fs'); | ||
const fileName = './src/config/config.json'; | ||
const file = require(fileName); | ||
|
||
file.prefix = '/inertia-client'; | ||
|
||
fs.writeFile(fileName, JSON.stringify(file), function writeJSON(err) { | ||
if (err) return console.log(err); | ||
console.log(JSON.stringify(file, null, 4)); | ||
console.log('writing to ' + fileName); | ||
}); | ||
|
||
exec('npm run build', defaultHandler); |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
[submodule "public/uv"] | ||
path = public/uv | ||
url = https://github.com/inertia-unblocker/uv-scripts |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,43 @@ | ||
/** @type {import('next').NextConfig} */ | ||
const config = require('./src/config/config.json'); | ||
const path = require('path'); | ||
|
||
module.exports = { | ||
webpack: (config, options) => { | ||
config.experiments = { | ||
topLevelAwait: true, | ||
layers: true, | ||
}; | ||
return config; | ||
webpack: (config) => { | ||
config.experiments = { | ||
topLevelAwait: true, | ||
layers: true, | ||
}; | ||
config.resolve.alias = { | ||
...config.resolve.alias, | ||
"@theme": path.resolve(__dirname, 'src/components/theme'), | ||
"@navigation": path.resolve(__dirname, 'src/components/navigation'), | ||
"@elements": path.resolve(__dirname, 'src/components/elements'), | ||
"@utils": path.resolve(__dirname, 'src/utils'), | ||
"@css": path.resolve(__dirname, 'src/css'), | ||
"@config": path.resolve(__dirname, 'src/config/config.json'), | ||
} | ||
|
||
return config; | ||
}, | ||
basePath: config.prefix, | ||
assetPrefix: config.prefix, | ||
async headers() { | ||
return [ | ||
{ | ||
// matching all API routes | ||
source: '/api/:path*', | ||
headers: [ | ||
{ key: 'Access-Control-Allow-Credentials', value: 'true' }, | ||
{ key: 'Access-Control-Allow-Origin', value: '*' }, | ||
{ key: 'Access-Control-Allow-Methods', value: 'GET,OPTIONS,PATCH,DELETE,POST,PUT' }, | ||
{ | ||
key: 'Access-Control-Allow-Headers', | ||
value: | ||
'X-CSRF-Token, X-Requested-With, Accept, Authorization, Accept-Version, Content-Length, Content-MD5, Content-Type, Date, X-Api-Version', | ||
}, | ||
], | ||
} | ||
]; | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,39 +1,35 @@ | ||
{ | ||
"name": "inertia-client", | ||
"private": false, | ||
"scripts": { | ||
"dev": "next dev", | ||
"build": "next build", | ||
"start": "next start", | ||
"lint": "next lint", | ||
"export": "next export", | ||
"update": "yarn upgrade --latest", | ||
"gh-pages-config": "node ./.gh-pages-setup.js" | ||
}, | ||
"dependencies": { | ||
"@nextui-org/react": "^1.0.0-beta.6", | ||
"axios": "^0.27.1", | ||
"imagemin-mozjpeg": "^10.0.0", | ||
"next": "^12.1.0", | ||
"next-themes": "^0.1.1", | ||
"react": "^17.0.2", | ||
"react-bootstrap": "^2.3.0", | ||
"react-cookie": "^4.1.1", | ||
"react-dom": "^17.0.2", | ||
"react-icons": "^4.3.1", | ||
"responsive-loader": "^2.3.0", | ||
"sharp": "^0.30.1", | ||
"tld-enum": "^2.0.6", | ||
"webp-loader": "^0.6.0" | ||
}, | ||
"devDependencies": { | ||
"@swc/core": "^1.2.172", | ||
"@types/node": "17.0.29", | ||
"@types/react": "18.0.8", | ||
"babel-plugin-module-resolver": "^4.1.0", | ||
"eslint": "8.14.0", | ||
"eslint-config-next": "12.1.5", | ||
"typescript": "4.6.3" | ||
}, | ||
"license": "GPL-3.0" | ||
} | ||
"name": "inertia-client", | ||
"private": false, | ||
"scripts": { | ||
"dev": "next dev", | ||
"build": "next build", | ||
"build:github": "node ./.gh-builder.js", | ||
"start": "next start", | ||
"lint": "next lint", | ||
"export": "next export", | ||
"update": "yarn upgrade --latest" | ||
}, | ||
"dependencies": { | ||
"@nextui-org/react": "^1.0.0-beta.9", | ||
"next": "^12.1.0", | ||
"next-themes": "^0.2.0", | ||
"react": "^17.0.2", | ||
"react-bootstrap": "^2.3.0", | ||
"react-cookie": "^4.1.1", | ||
"react-device-detect": "^2.2.2", | ||
"react-dom": "^17.0.2", | ||
"react-icons": "^4.3.1", | ||
"validator": "^13.7.0" | ||
}, | ||
"devDependencies": { | ||
"@types/node": "17.0.42", | ||
"@types/react": "18.0.12", | ||
"eslint": "8.17.0", | ||
"eslint-config-next": "12.1.6", | ||
"eslint-import-resolver-typescript": "^3.2.5", | ||
"eslint-plugin-import": "^2.26.0", | ||
"typescript": "4.7.3" | ||
}, | ||
"license": "GPL-3.0" | ||
} |
Oops, something went wrong.