-
-
Notifications
You must be signed in to change notification settings - Fork 99
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Use Next.js in studio-next (#1062)
- Loading branch information
1 parent
2c0ab6c
commit a4b7fd1
Showing
120 changed files
with
10,362 additions
and
227 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,5 @@ | ||
--- | ||
"studio-next": patch | ||
--- | ||
|
||
Use Next.js framework |
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,4 +1,4 @@ | ||
# Disable specific file since it would introduce more complexity to reduce it - mainly code complexity and complex template literals | ||
sonar.exclusions=apps/studio/public/js/monaco/**,apps/studio/src/tailwind.css,apps/studio/src/components/SplitPane/** | ||
# Disable duplicate code in tests since it would introduce more complexity to reduce it. | ||
sonar.cpd.exclusions=apps/studio/** | ||
sonar.cpd.exclusions=apps/studio/**,apps/studio-next/src/components/Navigationv3.tsx,apps/studio-next/src/components/Navigation.tsx |
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,4 +1,41 @@ | ||
/** @type {import('next').NextConfig} */ | ||
const nextConfig = {} | ||
const nextConfig = { | ||
webpack: ( | ||
config, | ||
{ buildId, dev, isServer, defaultLoaders, nextRuntime, webpack } | ||
) => { | ||
config.module.rules.push({ | ||
test: /\.yml$/i, | ||
type: 'asset/source', | ||
}) | ||
|
||
if (isServer) return config | ||
// Important: return the modified config | ||
config.resolve.fallback = { | ||
...config.resolve.fallback, | ||
assert: require.resolve('assert/'), | ||
buffer: require.resolve('buffer'), | ||
http: require.resolve('stream-http'), | ||
https: require.resolve('https-browserify'), | ||
path: require.resolve('path-browserify'), | ||
stream: require.resolve('stream-browserify'), | ||
zlib: require.resolve('browserify-zlib'), | ||
url: require.resolve('url/'), | ||
util: require.resolve('util/'), | ||
debug: false, | ||
canvas: false, | ||
fs: false, | ||
} | ||
|
||
config.plugins.push( | ||
new webpack.ProvidePlugin({ | ||
process: 'process/browser', | ||
Buffer: ['buffer', 'Buffer'], | ||
}) | ||
); | ||
|
||
return config | ||
}, | ||
} | ||
|
||
module.exports = 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
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,19 @@ | ||
# Redirect editor.asyncapi.org to Studio | ||
|
||
http://editor.asyncapi.org/* https://studio.asyncapi.com 301! | ||
https://editor.asyncapi.org/* https://studio.asyncapi.com 301! | ||
|
||
# Redirect playground.asyncapi.io to Studio | ||
|
||
http://playground.asyncapi.io/* https://studio.asyncapi.com/?redirectedFrom=playground 301! | ||
https://playground.asyncapi.io/* https://studio.asyncapi.com/?redirectedFrom=playground 301! | ||
|
||
http://playground.asyncapi.io/* load=:load https://studio.asyncapi.com/?redirectedFrom=playground&load=:load 301! | ||
https://playground.asyncapi.io/* load=:load https://studio.asyncapi.com/?redirectedFrom=playground&load=:load 301! | ||
http://playground.asyncapi.io/* load=:load readOnly=:readOnly https://studio.asyncapi.com/?redirectedFrom=playground&load=:load&readOnly=true 301! | ||
https://playground.asyncapi.io/* load=:load readOnly=:readOnly https://studio.asyncapi.com/?redirectedFrom=playground&load=:load&readOnly=true 301! | ||
|
||
http://playground.asyncapi.io/* url=:url https://studio.asyncapi.com/?redirectedFrom=playground&url=:url 301! | ||
https://playground.asyncapi.io/* url=:url https://studio.asyncapi.com/?redirectedFrom=playground&url=:url 301! | ||
http://playground.asyncapi.io/* url=:url readOnly=:readOnly https://studio.asyncapi.com/?redirectedFrom=playground&url=:url&readOnly=true 301! | ||
https://playground.asyncapi.io/* url=:url readOnly=:readOnly https://studio.asyncapi.com/?redirectedFrom=playground&url=:url&readOnly=true 301! |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.