xinyao27 / next-devtools Goto Github PK
View Code? Open in Web Editor NEWEnhancement Next Developer Experience
Home Page: https://next-devtools.vercel.app
License: MIT License
Enhancement Next Developer Experience
Home Page: https://next-devtools.vercel.app
License: MIT License
file:///home/ubuntu/node_modules/@next-devtools/core/dist/rpc-IPLRGAWM.js:106
import { loadEnvConfig } from "@next/env";
^^^^^^^^^^^^^
SyntaxError: Named export 'loadEnvConfig' not found. The requested module '@next/env' is a CommonJS module, which may not support all module.exports as named exports.
CommonJS modules can always be imported via the default export, for example using:
import pkg from '@next/env';
const { loadEnvConfig } = pkg;
at ModuleJob._instantiate (node:internal/modules/esm/module_job:132:21)
at async ModuleJob.run (node:internal/modules/esm/module_job:214:5)
at async ModuleLoader.import (node:internal/modules/esm/loader:329:24)
Operating System:
Platform: linux
Arch: arm64
Version: #13-Ubuntu SMP Sat Nov 18 06:20:29 UTC 2023
Binaries:
Node: 21.5.0
npm: 10.2.4
Yarn: N/A
pnpm: 8.10.5
Relevant Packages:
next: 14.0.5-canary.34
eslint-config-next: 14.0.4
react: 18.2.0
react-dom: 18.2.0
typescript: 5.3.3
Next.js Config:
output: standalone
the url in windows instead of "localhost" prints the current username, here's an example
start the provided example in windows
in windows url suppose to be "localhost" like in linux
here's the same example on my machine in linux
No response
I run pnpm dev
and it failed. These are the logs
➜ pnpm dev
> @next-devtools/[email protected] dev /Users/duncan/next-devtools
> npm-run-all --parallel dev:devtools dev:app
> @next-devtools/[email protected] dev:devtools /Users/duncan/next-devtools
> turbo dev
> @next-devtools/[email protected] dev:app /Users/duncan/next-devtools
> turbo dev:app
• Packages in scope: @next-devtools/client, @next-devtools/core, @next-devtools/shared, app-router, docs, pages-router
• Running dev:app in 6 packages
• Remote caching disabled
• Packages in scope: @next-devtools/client, @next-devtools/core, @next-devtools/shared, app-router, docs, pages-router
• Running dev in 6 packages
• Remote caching disabled
@next-devtools/shared:dev: cache bypass, force executing 84555c3d4d27ee87
app-router:dev:app: cache bypass, force executing f33b1bf9089e6ed6
@next-devtools/core:dev: cache bypass, force executing dcfc914a2b439a81
app-router:dev:app:
app-router:dev:app: > app-router@ dev:app /Users/duncan/next-devtools/playgrounds/app-router
app-router:dev:app: > next dev -p 3002
app-router:dev:app:
@next-devtools/core:dev:
@next-devtools/core:dev: > @next-devtools/[email protected] dev /Users/duncan/next-devtools/packages/devtools
@next-devtools/core:dev: > cross-env DEV=true tsup --watch
@next-devtools/core:dev:
@next-devtools/shared:dev:
@next-devtools/shared:dev: > @next-devtools/[email protected] dev /Users/duncan/next-devtools/packages/shared
@next-devtools/shared:dev: > tsup --watch
@next-devtools/shared:dev:
app-router:dev:app: node:internal/modules/cjs/loader:1098
app-router:dev:app: const err = new Error(`Cannot find module '${request}'`);
app-router:dev:app: ^
app-router:dev:app:
app-router:dev:app: Error: Cannot find module '/Users/duncan/next-devtools/playgrounds/app-router/node_modules/@next-devtools/core/dist/plugin.cjs'
app-router:dev:app: at createEsmNotFoundErr (node:internal/modules/cjs/loader:1098:15)
app-router:dev:app: at finalizeEsmResolution (node:internal/modules/cjs/loader:1091:15)
app-router:dev:app: at resolveExports (node:internal/modules/cjs/loader:567:14)
app-router:dev:app: at Module._findPath (node:internal/modules/cjs/loader:636:31)
app-router:dev:app: at Module._resolveFilename (node:internal/modules/cjs/loader:1063:27)
app-router:dev:app: at /Users/duncan/next-devtools/node_modules/.pnpm/[email protected][email protected][email protected][email protected]/node_modules/next/dist/server/require-hook.js:55:36
app-router:dev:app: at Module._load (node:internal/modules/cjs/loader:922:27)
app-router:dev:app: at Module.require (node:internal/modules/cjs/loader:1143:19)
app-router:dev:app: at mod.require (/Users/duncan/next-devtools/node_modules/.pnpm/[email protected][email protected][email protected][email protected]/node_modules/next/dist/server/require-hook.js:65:28)
app-router:dev:app: at require (node:internal/modules/cjs/helpers:110:18) {
app-router:dev:app: code: 'MODULE_NOT_FOUND',
app-router:dev:app: path: '/Users/duncan/next-devtools/playgrounds/app-router/node_modules/@next-devtools/core/package.json'
app-router:dev:app: }
app-router:dev:app:
app-router:dev:app: Node.js v18.17.0
app-router:dev:app: ELIFECYCLE Command failed with exit code 1.
app-router:dev:app: ERROR: command finished with error: command (/Users/duncan/next-devtools/playgrounds/app-router) /opt/homebrew/bin/pnpm run dev:app exited (1)
app-router#dev:app: command (/Users/duncan/next-devtools/playgrounds/app-router) /opt/homebrew/bin/pnpm run dev:app exited (1)
Tasks: 0 successful, 1 total
Cached: 0 cached, 1 total
Time: 2.342s
Failed: app-router#dev:app
ERROR run failed: command exited (1)
ELIFECYCLE Command failed with exit code 1.
@next-devtools/shared:dev: ELIFECYCLE Command failed.
ELIFECYCLE Command failed.
@next-devtools/core:dev: ELIFECYCLE Command failed with exit code 1.
ERROR: "dev:app" exited with 1.
ELIFECYCLE Command failed with exit code 1.
I try it in Next.js 12 and it doesn't work because next/navigation doesn't exist so this should be added to the requirements
No response
No response
I would like to be able to disclose a security vulnerability.
It would be great if you could create a SECURITY.md file and enable Private Vulnerability Reporting.
No response
No response
npm dev
localhost:3000
dev tools should not fail to build with pages router
i tried the example in both linux and windows
node.js version: v18.19.0
npm version: 10.2.3
next.js version(using pages router):14.0.4
dev tools version: 0.1.2
I think this would be nice as this is very inspired by it, and giving credits in the open source is IMO the minimum you can do 😊
Linking to https://github.com/nuxt/devtools
No response
With the latest version (0.1.3) the dev tools are working, but no routes are shown.
https://github.com/noxify/next-documentation
After opening the dev tools modal or the dedicated devtools page, the "registered" routes are shown.
I tested it in my test monorepo ( see link ).
Just run the following commands:
git clone [email protected]:noxify/next-documentation.git
cd next-documentation
pnpm i
pnpm dev
If you need additional information, please let me know
This issue can be traced back to this Issue: vercel/next.js#59457 (comment)
Currently, the lack of __debugSource
in the app router makes it impossible to trace the component file path.
You can try adding @babel/plugin-transform-react-jsx-source
or @react-dev-inspector/babel-plugin
to .babelrc.js
or babel.config.js
:
// https://nextjs.org/docs/advanced-features/customizing-babel-config
module.exports = {
presets: [
'next/babel',
],
plugins: [
'@react-dev-inspector/babel-plugin',
],
}
For more information, please refer to: https://react-dev-inspector.zthxxx.me/docs/compiler-plugin
I'm getting this error: GET http://localhost:3000/__next_devtools__/client 500 (Internal Server Error)
Everything setup as per the pages option, when firing run dev.
To display the panel.
No response
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.