New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: teach unstable_dev about the internet (remote mode) #1967
Conversation
TIL Create wet-pens-watch.md refactor remote to use common functions wip wip wip
🦋 Changeset detectedLatest commit: b62df56 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
A wrangler prerelease is available for testing. You can install this latest build in your project with: npm install --save-dev https://prerelease-registry.developers.workers.dev/runs/3159311155/npm-package-wrangler-1967 You can reference the automatically updated head of this PR with: npm install --save-dev https://prerelease-registry.developers.workers.dev/prs/1967/npm-package-wrangler-1967 Or you can use npx https://prerelease-registry.developers.workers.dev/runs/3159311155/npm-package-wrangler-1967 dev path/to/script.js Additional artifacts:npm install https://prerelease-registry.developers.workers.dev/runs/3159311155/npm-package-cloudflare-pages-shared-1967 |
This is ready for review, I just need a functioning API key + account ID to make the tests pass. |
Codecov Report
@@ Coverage Diff @@
## main #1967 +/- ##
==========================================
- Coverage 74.91% 72.73% -2.19%
==========================================
Files 116 118 +2
Lines 7962 8230 +268
Branches 2079 2160 +81
==========================================
+ Hits 5965 5986 +21
- Misses 1997 2244 +247
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! I am excited to see this in action in the wild 😄
How to review this PR:
fixtures/local-mode-tests/tests/unstableDev.test.ts
, where we callunstable_dev
withlocal: false
packages/wrangler/src/api/dev.ts
, and make it possible to configure thelocal
setting inunstable_dev
packages/wrangler/src/dev.tsx
, instartApiDev
packages/wrangler/src/dev/start-server.ts
, where we passlocal
tostartDevServer
, which uses it to decide whether to start a local, or remote serverpackages/wrangler/src/dev/remote.tsx
packages/wrangler/src/proxy.ts
, which gets called bystartRemoteServer
aboveCloses #1780