-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
cbf1086
commit e2bc677
Showing
33 changed files
with
836 additions
and
11 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 |
---|---|---|
@@ -0,0 +1,11 @@ | ||
root = true | ||
|
||
[*] | ||
end_of_line = lf | ||
insert_final_newline = true | ||
indent_style = space | ||
indent_size = 2 | ||
|
||
[{*.json,.*.yml}] | ||
indent_style = space | ||
indent_size = 2 |
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 @@ | ||
.next | ||
dist | ||
node_modules/ |
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,8 @@ | ||
{ | ||
"extends": ["next", "prettier", "plugin:tailwind/recommended"], | ||
"rules": { | ||
"import/prefer-default-export": "off", | ||
"no-console": "warn", | ||
"no-var": "error" | ||
} | ||
} |
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,10 +1,50 @@ | ||
# [MM] HEY HEY HEY | ||
assets | ||
pnpm-lock.yaml | ||
|
||
# dependencies | ||
node_modules | ||
web_modules | ||
.firebase | ||
.firebaserc | ||
.glitchdotcom.json | ||
|
||
# testing | ||
coverage | ||
|
||
# next.js | ||
.next | ||
out | ||
|
||
# production | ||
build | ||
|
||
# [MM] HEY HEY HEY | ||
assets | ||
pnpm-lock.yaml | ||
# misc | ||
.DS_Store | ||
*.pem | ||
|
||
# debug | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
|
||
# local env files | ||
.env.local | ||
.env.development.local | ||
.env.test.local | ||
.env.production.local | ||
|
||
# vercel | ||
.vercel | ||
|
||
# next-pwa | ||
public/workbox-*.js | ||
public/sw.js | ||
|
||
# prefer yarn than npm | ||
package-lock.json | ||
|
||
report.*.json | ||
|
||
# .vscode Debugging | ||
.vscode/*-debug-profile |
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,7 @@ | ||
build/* | ||
dist/* | ||
public/* | ||
.next/* | ||
node_modules/* | ||
package.json | ||
*.log |
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,18 @@ | ||
{ | ||
"arrowParens": "always", | ||
"bracketSpacing": true, | ||
"embeddedLanguageFormatting": "auto", | ||
"htmlWhitespaceSensitivity": "css", | ||
"insertPragma": false, | ||
"jsxSingleQuote": true, | ||
"printWidth": 80, | ||
"proseWrap": "preserve", | ||
"quoteProps": "as-needed", | ||
"requirePragma": false, | ||
"semi": false, | ||
"singleQuote": true, | ||
"tabWidth": 2, | ||
"trailingComma": "es5", | ||
"useTabs": false, | ||
"vueIndentScriptAndStyle": false | ||
} |
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,9 @@ | ||
{ | ||
"editor.formatOnPaste": true, | ||
"editor.formatOnSave": true, | ||
"editor.codeActionsOnSave": { | ||
"source.fixAll": true | ||
}, | ||
"eslint.validate": ["javascript"], | ||
"eslint.workingDirectories": [{ "mode": "auto" }] | ||
} |
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,9 @@ | ||
// @js-ignore | ||
{ | ||
"compilerOptions": { | ||
"baseUrl": ".", | ||
"paths": { | ||
"@/*": ["src/*"] | ||
} | ||
} | ||
} |
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,69 @@ | ||
const withBundleAnalyzer = require('@next/bundle-analyzer')({ | ||
enabled: process.env.ANALYZE === 'true', | ||
}) | ||
const withPWA = require('next-pwa') | ||
const runtimeCaching = require('next-pwa/cache') | ||
|
||
const nextConfig = { | ||
webpack(config, { isServer }) { | ||
// audio support | ||
config.module.rules.push({ | ||
test: /\.(ogg|mp3|wav|mpe?g)$/i, | ||
exclude: config.exclude, | ||
use: [ | ||
{ | ||
loader: require.resolve('url-loader'), | ||
options: { | ||
limit: config.inlineImageLimit, | ||
fallback: require.resolve('file-loader'), | ||
publicPath: `${config.assetPrefix}/_next/static/images/`, | ||
outputPath: `${isServer ? '../' : ''}static/images/`, | ||
name: '[name]-[hash].[ext]', | ||
esModule: config.esModule || false, | ||
}, | ||
}, | ||
], | ||
}) | ||
|
||
// shader support | ||
config.module.rules.push({ | ||
test: /\.(glsl|vs|fs|vert|frag)$/, | ||
exclude: /node_modules/, | ||
use: ['raw-loader', 'glslify-loader'], | ||
}) | ||
|
||
return config | ||
}, | ||
} | ||
|
||
// manage i18n | ||
if (process.env.EXPORT !== 'true') { | ||
nextConfig.i18n = { | ||
locales: ['en-US'], | ||
defaultLocale: 'en-US', | ||
} | ||
} | ||
|
||
module.exports = (_phase, { defaultConfig }) => { | ||
const plugins = [ | ||
[ | ||
withPWA, | ||
{ | ||
pwa: { | ||
dest: 'public', | ||
disable: process.env.NODE_ENV === 'development', | ||
runtimeCaching, | ||
}, | ||
}, | ||
], | ||
[withBundleAnalyzer, {}], | ||
] | ||
|
||
return plugins.reduce( | ||
(acc, [plugin, config]) => plugin({ ...acc, ...config }), | ||
{ | ||
...defaultConfig, | ||
...nextConfig, | ||
} | ||
) | ||
} |
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,53 @@ | ||
{ | ||
"name": "react-three-next", | ||
"version": "2.0.0", | ||
"authors": [ | ||
"Renaud ROHLINGER <https://twitter.com/onirenaud>" | ||
], | ||
"license": "MIT", | ||
"private": true, | ||
"engines": { | ||
"node": ">=14" | ||
}, | ||
"scripts": { | ||
"lint": "yarn prettier && yarn eslint", | ||
"eslint": "next lint --fix --dir src", | ||
"prettier": "prettier -l \"./src/**/*.{js,jsx,md}\"", | ||
"dev": "next dev", | ||
"build": "next build", | ||
"export": "EXPORT=true next build && EXPORT=true next export", | ||
"analyze": "ANALYZE=true next build", | ||
"start": "next start" | ||
}, | ||
"dependencies": { | ||
"@babel/plugin-transform-runtime": "^7.17.0", | ||
"@react-three/drei": "^9.14.3", | ||
"@react-three/fiber": "^8.0.27", | ||
"babel-plugin-glsl": "^1.0.0", | ||
"glsl-random": "^0.0.5", | ||
"next": "^12.2.3", | ||
"next-pwa": "^5.5.4", | ||
"react": "^18.2.0", | ||
"react-dom": "^18.2.0", | ||
"three": "^0.142.0", | ||
"three-stdlib": "^2.12.1", | ||
"zustand": "^4.0.0" | ||
}, | ||
"devDependencies": { | ||
"@next/bundle-analyzer": "^12.2.3", | ||
"autoprefixer": "^10.4.2", | ||
"eslint": "^8.20.0", | ||
"eslint-config-next": "^12.2.3", | ||
"eslint-config-prettier": "^8.5.0", | ||
"eslint-plugin-tailwind": "^0.2.1", | ||
"file-loader": "^6.2.0", | ||
"glslify": "^7.1.1", | ||
"glslify-loader": "^2.0.0", | ||
"next-offline": "^5.0.5", | ||
"postcss": "^8.4.14", | ||
"prettier": "^2.7.1", | ||
"raw-loader": "^4.0.2", | ||
"tailwindcss": "^3.1.6", | ||
"url-loader": "^4.1.1" | ||
} | ||
} |
Oops, something went wrong.