Commit graph

2486 commits

Author SHA1 Message Date
Rishi Raj Jain
b99f9902b7
fix: "chunks" directory appears in build output, if custom modules are imported in Astro files (#4868) 2022-09-26 18:01:44 +08:00
matthewp
32f489b136 [ci] format 2022-09-23 17:29:01 +00:00
Matthew Phillips
49ca9e1291
Define toStringTag another way (#4855)
* Define toStringTag another way

* Adding a changeset
2022-09-23 13:27:07 -04:00
matthewp
4ff61626a1 [ci] format 2022-09-23 12:10:59 +00:00
Rishi Raj Jain
edb7bead6e
fix: Can't overwrite vite's MODE environment variable (#4850)
* Add flags to the build options

* replace mode: 'production' as fallback

* Update mode support

* Add changeset
2022-09-23 08:08:57 -04:00
Rishi Raj Jain
ee5fdeffdd
fix: getFileInfo does not add .html extension in url when build.format is file (#4849)
* Create appendExtension

* Add html to file URLs if build.format is file

* Add changeset
2022-09-23 08:07:27 -04:00
Gerard de Brieder
944d24e9ee
Update Picture.astro so it no longer passes height and width attributes (#4797)
* Update Picture.astro

the image variable of getPicture contains a width and height property, which we usually require. In this case, the image is wrapped in a picture tag and the img tag itself should not have a width and height property as this will break the responsiveness of the image provided by the picture tag.

* added changeset

* fixing SSG picture tests that were expecting img dimensions

Co-authored-by: Tony Sullivan <tony.f.sullivan@outlook.com>
2022-09-22 21:01:38 +00:00
matthewp
a5df3f313e [ci] format 2022-09-22 20:39:53 +00:00
Rishi Raj Jain
4b092269c1
Resolves #4825 (#4841)
* Resolves #4825

* Add changeset

* Update late-cups-jam.md

* Update late-cups-jam.md
2022-09-22 16:37:49 -04:00
Matthew Phillips
3389f0ce91
Prevent the root from being deleted during the build (#4845)
* Prevent the root from being deleted during the build

* Adding a changeset
2022-09-22 16:37:16 -04:00
tony-sull
426f3bb40f [ci] format 2022-09-22 19:50:47 +00:00
Tony Sullivan
fad3867adb
Adding an optional image service based on Squoosh (#4738)
* WIP: adding a service built on @squoosh/lib

* WIP: investigating memory leaks in Squoosh

* WIP: vendoring Squoosh to work with our build

* chore: a bit of cleanup and a small perf gain

* removing a few unused deps

* fix: removing temp .only() in sharp test

* hooking up the last build steps to copy over .wasm files

* removing the duplicated lib/*.wasm files

* defaulting to Sharp for the initial @next release

* make sure pnpm always runs the postbuild script

* removing a few node dependencies

* refactor: move the copy .wasm build step out of the SSR bundle

* linter fixes

* fixing lock file

* chore: add TEMP changeset

* fix built wasm location for SSG builds

* Revert "defaulting to Sharp for the initial @next release"

This reverts commit 1a8d4f7f60.

* removing sharp dependency

* Revert "fix built wasm location for SSG builds"

This reverts commit 446b80bb53.

* chore: update lockfile

* fixing up image tests for the wasm loader

* updating the README for squoosh

* parallel wasm builds

* refactor: a bit of house keeping

* perf: allow a thread for each output encoding format

* fix: dev broke with the shift to wasm workers

* adds a new `astro:build:generated` hook for SSG builds

* fix: typo + calling cleanup methods in wasm codecs

* adding @astrojs/webapi for the TransformStream polyfill

* Revert "adding @astrojs/webapi for the TransformStream polyfill"

This reverts commit 39e5b845a5.

* perf: using sharp for most of the CI tests

* chore: update lockfile

* removing hard-coded squoosh imports

* fix: adding sharp to rollup externals

* test: using dev for the squoosh tests

* fix: updating the build output dir for wasm filles in SSG builds

* updating the changeset with migration details

* Revert "adds a new `astro:build:generated` hook for SSG builds"

This reverts commit 59b5fec7be.

* nit: adding comments for the wasm file copy

* chore: fix eslint warning
2022-09-22 19:48:14 +00:00
Bjorn Lu
6a1a17dd28
Add CSS @import test (#4454)
* Add css hmr test

* Allow HMR in e2e tests

* Add changeset

* Actually fix test

* Fix lint

* Skip windows for now
2022-09-22 15:06:49 -04:00
matthewp
5e568e4a14 [ci] format 2022-09-22 19:05:57 +00:00
Happydev
08dae16161
feat(vite-plugin-markdown): support importing markdown files from outside root project (#4780)
* feat: support importing markdown from outside root project

This change adds support for importing markdown located outside the root of directory of a project

* refactor how the "jsx-runtime" module path is retrieved

* refactor: split type imports and function import

Pattern I've seen repeated a lot in the repo

* fix: chaotic marge conflict mistake

Co-authored-by: Matthew Phillips <matthew@skypack.dev>
2022-09-22 15:04:03 -04:00
matthewp
d2853ebe66 [ci] format 2022-09-22 18:50:12 +00:00
Zicklag
5e4c5252bd
Http proxy for fetch (#4676)
* Add HTTP Proxy Support to `fetch` Polyfill

Use `global-agent` to support HTTP_PROXY, HTTPS_PROXY, and NO_PROXY
environment variables.

* Add Changeset For HTTP Proxy Support in `fetch`
2022-09-22 14:47:06 -04:00
matthewp
6ce8ae261f [ci] format 2022-09-22 18:39:14 +00:00
Michael Rienstra
7481ffda02
create-astro: always create tsconfig.json (#4810)
* `create-astro`: always create `tsconfig.json`

Currently, we only make sure `tsconfig.json` exists when `strict` or `strictest` is selected. Both `default` & `optout` are intended to correspond to `base` -- and will do so for all [23 official templates](https://github.com/withastro/astro/tree/main/examples), but not necessarily for third-party templates.

The [example command for installing a third-party template](https://github.com/withastro/astro/blob/a800bf7/packages/create-astro/README.md?plain=1#L31-L35) is (rather conveniently for the sake of this PR!) an example of a template without a `tsconfig.json` file, and installing it with the `default` ("Relaxed") Typescript option results in no `tsconfig.json` file, rather than a `tsconfig.json` file containing `{ "extends": "astro/tsconfigs/base" }` as would be expected.

This PR addresses this scenario. 

It also explicitly sets the `tsconfig.json` file to `{ "extends": "astro/tsconfigs/base" }` when `default` (which I renamed to `base`, still presented to the user as "Relaxed") or `optout` is selected (`optout` has always printed a warning about the importance of `tsconfig.json` & `src/env.d.ts` but otherwise behaved identically to `default`). This is necessary in two scenarios:

1. When the `tsconfig.json` file was created by this script.
2. When it either didn't already include `"extends"`, or it extended a different config by default. For example, some third-party templates might default to `strict`, in which case I'm guessing we'd want to respect the user's choice and change that to `base`.

* update `del` 6.1.1 --> 7.0.0

* test: prevent excess writes
(without this it triggers many times)

* test: create-astro typescript prompt

* changeset

* fix: recursive `mkdirSync`

* test: longer timeout for `windows-latest` OS
(see if this fixes failing tests)

* better glob path creation, don't hardcode `/`

* test: longer timeout for windows-latest OS
(since I'm about to trigger another CI run by pushing a commit, might as well try this too)

* create-astro test: show last CLI output on timeout

* drop variable timeout
Typescript tests are slower than directory tests, but they are all usually less than 5000 ms. Less complexity, easier to maintain.

* DRY new error output

* Update lockfile

* Sync lockfile with main

* Update lockfile

Co-authored-by: Princesseuh <princssdev@gmail.com>
2022-09-22 14:37:01 -04:00
Ben Holmes
e5f71142eb
docs: add MDXLayoutProps to README (#4700)
* docs: add MDXLayoutProps to README

* chore: changeset

* nit: remove "if you understand this diff"

* nit: AdD tYpE sAfEtY

Co-authored-by: Chris Swithinbank <swithinbank@gmail.com>

* Update packages/integrations/mdx/README.md

Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>

Co-authored-by: Chris Swithinbank <swithinbank@gmail.com>
Co-authored-by: Matthew Phillips <matthew@skypack.dev>
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
2022-09-22 14:35:37 -04:00
梁峰宁
17dbc67018
Fix slashes for paths containing non-ASCII characters on Windows. (#4712)
* Fix slashes for paths containing non-ASCII characters on Windows.

* Add non-ASCII path test

* Fix slashes in pnpm-lock.yaml
2022-09-22 14:33:28 -04:00
Erika
e9eb4d1f3d
Fix ESLint not working in CI (#4837)
* Update ESLint extensions

* Use fredkbot

* Only use fredkbot for the commit

* Disable autofix

* Fix lint error
2022-09-22 11:37:41 -04:00
Fred K. Bot
47d4165603
[ci] release (#4833)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2022-09-22 11:04:45 -04:00
Matthew Phillips
25a5b9a89a
Revert preact signals support (#4843)
* Revert "Update preact example to match @astrojs/preact ranges (#4840)"

This reverts commit d650a1161a.

* Revert "[ci] format"

This reverts commit e3c78c5b16.

* Revert "Support shared signals in Preact islands (#4763)"

This reverts commit 5e46be5468.
2022-09-22 10:32:42 -04:00
Michael Rienstra
b0efb83252
docs: integrations: yarn & pnpm (#4836) 2022-09-22 08:16:02 -03:00
matthewp
778dce8c05 [ci] format 2022-09-21 23:09:40 +00:00
Matthew Phillips
73f215df76
Allow passing fetch() Response to set:html (#4832)
* ALlow passing fetch() Response to set:html

* Only check for Symbol.iterator on objects

* oops

* Fix no-streaming case

* Remove old comment
2022-09-21 19:07:00 -04:00
matthewp
b4c5c8ef57 [ci] format 2022-09-21 19:56:15 +00:00
董雨航
29b29e6a8a
Fix: Invalid hook call when user use export jsx function (#4831)
* update vite-jsx-plugin for export

* update vite-jsx-plugin for export

* update changeset level

Co-authored-by: Yuhang <dong_yu_hang@126.com>
2022-09-21 15:53:58 -04:00
matthewp
e3c78c5b16 [ci] format 2022-09-21 19:23:58 +00:00
Matthew Phillips
5e46be5468
Support shared signals in Preact islands (#4763)
* Support signals in Preact islands

* Add a changeset

* Only add signals if we need them

* Refactor signal logic into its own module

* Keep track of the signals used
2022-09-21 15:21:21 -04:00
Erika
baae1b3fd1
Update astro check to latest version of the language server (#4754)
* Update to latest version of the language server

* Add changeset
2022-09-21 15:15:04 -03:00
Bjorn Lu
a0619f0869
Refactor server url logs (#4509)
* Refactor server url logs

* Fix test

* Fix build
2022-09-21 13:25:16 -04:00
Tony Sullivan
b0cc939961
Adds a new "astro:build:generated" hook for SSG builds (#4775)
* Revert "Revert "Adds a new "astro:build:generated" hook for SSG builds (#4772)" (#4774)"

This reverts commit 13a4b0d488.

* fix: updating for latest merge with main
2022-09-21 17:13:36 +00:00
matthewp
bcc52540a5 [ci] format 2022-09-21 16:23:49 +00:00
aggre
a961aa3c2f
Supports Uint8Array/Uint16Array/Uint32Array for serialize props (#4669)
* supports Uint8Array/Uint16Array/Uint32Array

* update astro-island to supports the added types

* run changeset

* apply format

* pass metadata through

* using Array type

* write test cases for serializing Uint8Array/Uint16Array/Uint32Array

* fix the broken test cases

* add type assertion for psychological safety

* this changes is minor change

* feat: serialize UintArrays directly

* Update index.ts

Co-authored-by: Matthew Phillips <matthew@skypack.dev>
Co-authored-by: Nate Moore <nate@astro.build>
Co-authored-by: Nate Moore <natemoo-re@users.noreply.github.com>
2022-09-21 12:19:30 -04:00
Fred K. Bot
5684a016bb
[ci] release (#4823)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2022-09-20 16:55:48 -04:00
tony-sull
b2c9059ed8 [ci] format 2022-09-20 20:28:39 +00:00
Oussama Bennaci
ea37de86e4
[@astrojs/image] flatten background only if alpha channel isn't supported (#4800)
* Use sharp flatten only when format doesnt support alpha

* Allow rgba for background prop

* Add changeset

* Adjust doc

* Fix tests
2022-09-20 20:25:45 +00:00
Fred K. Bot
a76b0aa27c
[ci] release (#4822)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2022-09-20 16:05:13 -04:00
matthewp
0f4f514fd9 [ci] format 2022-09-20 19:34:51 +00:00
Matthew Phillips
9bfbd63f05
Fixes processing of images in Netlify functions (#4820) 2022-09-20 15:33:01 -04:00
Fred K. Bot
a08b178cdb
[ci] release (#4811)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2022-09-20 15:15:54 -04:00
matthewp
abfe73f5dc [ci] format 2022-09-20 17:15:15 +00:00
Matthew Phillips
518e8f7e25
Allow passing promises to set:html (#4819)
* Allow passing promises to set:html

* Adding a changeset
2022-09-20 13:13:21 -04:00
matthewp
666d98e3ec [ci] format 2022-09-20 16:39:24 +00:00
Daniel
ce0b92ba73
update cloudflare esbuild config (fixing solid ssr) (#4815)
* fixing esbuild platform setting, to enable solid build

* added changeset

* changed change to major

Co-authored-by: AirBorne04 <daniel@floatingpixels.com>
2022-09-20 12:36:58 -04:00
Mohammed Elhaouari
a49bc2f02e
Fix extra slash when adding integrations that ends with /astro (#4817)
* fix toIdent util

* add changesets
2022-09-20 12:36:40 -04:00
matthewp
91568bb055 [ci] format 2022-09-20 13:40:04 +00:00
Matthew Phillips
8d059faaed
Prevent errors in React components from crashing the dev server (#4816)
* Prevent errors in React components from crashing the dev server

* Add a changeset

* Fix test when running in the build
2022-09-20 09:38:17 -04:00
matthewp
57ea549e11 [ci] format 2022-09-20 12:34:55 +00:00
Enteleform
f53d97d56b
[chore] replaces hard-coded minify values with vite.build.minify (#4803)
* [chore] replaces hard-coded `minify` values with `vite.build.minify`

* [style] changes ternary to not-equals

Co-authored-by: Bjorn Lu <bjornlu.dev@gmail.com>

* [chore] removes `minify` in favor of user config & Vite defaults

Co-authored-by: Bjorn Lu <bjornlu.dev@gmail.com>
2022-09-20 08:32:58 -04:00
HiDeoo
c84d85ba4d
Add support for running create-astro in cloned empty git repository (#4805) 2022-09-20 08:30:13 -04:00
Bjorn Lu
be9eaa0692
Allow override vite.build.target (#4813) 2022-09-20 08:12:13 -04:00
Luca Casonato
44fa378186
Remove explicit Transfer-Encoding: chunked header (#4807)
* Remove explicit `Transfer-Encoding: chunked`

This header is not necessary and is ignored by essentially all HTTP
servers when provided explicitly by the user. This is because the HTTP
transport layer handles adding this header automatically as needed.

Some variations of HTTP transport (like HTTP/2, which is enabled by
default in Deno, Netlify, and CFW) have no notion of
`Transfer-Encoding: chunked`, because all responses are streamed.

* add changeset
2022-09-20 07:59:10 -04:00
Kristoffer K
df54595a88
fix(markdown-remark): declare hast-util-to-html as a dependency (#4787) 2022-09-20 17:21:54 +08:00
Fred K. Bot
8a1dd4b7e8
[ci] release (#4790)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2022-09-19 14:44:49 -04:00
Aditya Jain
620f1d9e1e
fixed broken emoji for in "Getting started" section of integration docs (#4795)
* fixed broken emoji for "nest frameworks together"

* Add missing whitespace

Co-authored-by: Yan Thomas <61414485+Yan-Thomas@users.noreply.github.com>
2022-09-19 12:58:06 -03:00
Bjorn Lu
cf5ed5f3a8
Update Vite 3.1.3 (#4802) 2022-09-19 11:46:05 -04:00
matthewp
a2b0bef050 [ci] format 2022-09-17 16:35:02 +00:00
Matthew Phillips
8f9463e07f
Fixes client:only CSS in Svelte components (#4782)
* Fixes client:only CSS in Svelte components

* Add changeset
2022-09-17 12:32:35 -04:00
Fred K. Bot
1c36b0ec18
[ci] release (#4781)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2022-09-16 14:13:02 -04:00
Fred K. Schott
59c36897de
Update CHANGELOG.md (#4743) 2022-09-16 14:04:39 -04:00
Michael Rienstra
a800bf7ec1
.md only: npm init astro --> npm create astro (#4760)
* .md only: npm init astro --> npm create astro

For consistency with https://github.com/withastro/docs/pull/360. Docs always use `npm create astro` (never `npm init astro`), README.md files in this repo should do the same.

Search:
`\b(npm|yarn|pnpm) init astro\b`
Replace:
`$1 create astro`

Except for two instances:

1. `packages/create-astro/CHANGELOG.md` -- skipped because changelog.

2. `packages/create-astro/test/create-astro.test.js.skipped` -- skipped, old test disabled in https://github.com/withastro/astro/pull/3168.

* docs: add `@latest` to `npm create astro`
Co-authored-by: Bjorn Lu <bjorn@bjornlu.com>

Co-authored-by: Michael Rienstra <michael@goodmoney.com>
2022-09-16 12:40:06 -05:00
matthewp
64aa903f04 [ci] format 2022-09-16 15:31:14 +00:00
Matthew Phillips
f3a81d82f6
Refactor to remove AstroConfig['_ctx'] (#4771)
* Refactor to remove AstroConfig['_ctx']

* Fix type error

* Export validateConfig

* Move to an options bag for createSettings

* Move config tests into test/untils/config

* Add a changeste

* fix build
2022-09-16 11:29:17 -04:00
tony-sull
8cc7dc1bcd [ci] format 2022-09-15 21:26:37 +00:00
Tony Sullivan
13a4b0d488
Revert "Adds a new "astro:build:generated" hook for SSG builds (#4772)" (#4774)
This reverts commit 03b18e8d1b.
2022-09-15 21:24:23 +00:00
tony-sull
7acded4d0e [ci] format 2022-09-15 21:03:49 +00:00
Tony Sullivan
03b18e8d1b
Adds a new "astro:build:generated" hook for SSG builds (#4772)
* adds a new "astro:build:generated" hook for SSG builds

* chore: add changeset
2022-09-15 21:02:07 +00:00
Fred K. Bot
b2da8a124a
[ci] release (#4761)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2022-09-15 14:05:25 -04:00
matthewp
e40d8d8357 [ci] format 2022-09-15 16:36:38 +00:00
Matthew Phillips
9a59e24e02
Ensure before-hydration is only loaded when used (#4768)
* Ensure before-hydration is only loaded when used

* client fix + changeset
2022-09-15 12:33:52 -04:00
matthewp
c7c3cf7104 [ci] format 2022-09-15 13:53:30 +00:00
Matthew Phillips
fc885eaea1
Read jsxImportSource from tsconfig (#4759)
* Read jsxImportSource from tsconfig

* Only read from tsconfig if not found earlier
2022-09-15 09:50:48 -04:00
Chris Swithinbank
0398efa39f
Tailwind v2 docs (#4758)
* Add migration notes to Tailwind changelog

* Include `tailwindcss` in manual install steps

* add changeset
2022-09-14 22:43:10 +02:00
Fred K. Bot
27aa9851d8
[ci] release (#4750)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2022-09-14 16:06:23 -04:00
matthewp
a74f246333 [ci] format 2022-09-14 19:49:26 +00:00
Matthew Phillips
005d5bacd9
Allow custom 404 route to handle API route missing methods (#4594)
* Properly allow file uploads in the dev server

* Allow custom 404 route to handle API route missing methods

* Add a changeset

* what was i thinking

* Pass through the pathname

* Move the try/catch out and into handleRequest

* await the result of handleRoute
2022-09-14 15:47:16 -04:00
matthewp
04daafbbdf [ci] format 2022-09-14 19:44:27 +00:00
Matthew Phillips
c271ed35ee
Only pass through children prop if there are children (#4756) 2022-09-14 15:42:38 -04:00
aFuzzyBear
098c76717a [ci] format 2022-09-14 19:19:56 +00:00
Peter Singh
664ebf449e
Update peer dep with Tailwindcss (#4543)
* Update peer dep

* Create leaders-of-the-free-world.md

Update: `@astrojs/tailwindcss` project with `tailwindcss` as a `peer-dependency`

* Removed tailwindcss as 'dependency'

* Update `pnpm-lock` with changes to deps

* Update .changeset/leaders-of-the-free-world.md

Co-authored-by: Bjorn Lu <bjornlu.dev@gmail.com>

Co-authored-by: Bjorn Lu <bjornlu.dev@gmail.com>
2022-09-14 20:17:04 +01:00
matthewp
5e690065f7 [ci] format 2022-09-14 17:54:33 +00:00
Matthew Phillips
f1efd88dde
Compatiblity between hoisted scripts and tailwind integration (#4755)
* Compatiblity between hoisted scripts and tailwind integration

* Adds a changeset
2022-09-14 13:51:38 -04:00
Bjorn Lu
1bedb9427e
Support Vite 3.1 (#4752)
* Support Vite 3.1

* Update ~3.1.0

* Revert Vite bump
2022-09-14 12:01:50 -04:00
Bjorn Lu
c5e134d035
Fix console.error filtering (#4748) 2022-09-14 22:08:34 +08:00
Bjorn Lu
13ca686ea1
Handle builds with outDir outside of cwd (#4736) 2022-09-14 21:24:35 +08:00
matthewp
a36d51d433 [ci] format 2022-09-14 11:59:49 +00:00
Matthew Phillips
cf8a7e933d
Properly handle multipart file uploads in the dev server (#4742)
* Properly allow file uploads in the dev server

* Smaller image

* movethe test over
2022-09-14 07:58:00 -04:00
Fred K. Bot
150cd8a582
[ci] release (#4729)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2022-09-13 15:15:05 -04:00
Nate Moore
8cfb3fb535
Migrate examples to type: module (#4662)
* chore: move examples to type module

* chore: prefer astro.config.mjs to astro.config.js

* chore: reference CJS config file

Co-authored-by: Nate Moore <nate@astro.build>
2022-09-13 14:02:57 -05:00
Ben Holmes
4bc70f3545
Fix route validation for Netlify Edge (#4722)
* fix: serialize route pattern for Netlify edge

Co-authored-by: Jackie Macharia <jackiewmacharia>

* chore: changeset
2022-09-12 19:33:44 -04:00
matthewp
8903edee88 [ci] format 2022-09-12 20:37:25 +00:00
Matthew Phillips
6efafa4b0e
Use import order to sort CSS in prod (#4724)
* Use import order to sort CSS in prod

* Adding a changeset

* Pass through the parent id

* Update remaining test
2022-09-12 16:35:39 -04:00
Fred K. Bot
56e225b41a
[ci] release (#4707)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2022-09-12 15:08:39 -04:00
Ben Holmes
6e1d62fe22
[RSS] Fix failure when globbing index route (#4701)
* fix: [rss] throw on undefined urls only

* test: "" url, passing glob outside pages/

* chore: changeset
2022-09-12 15:05:57 -04:00
matthewp
d614be4900 [ci] format 2022-09-12 18:43:54 +00:00
Juan Martín Seery
16113c3ae2
[vercel] Use Edge Functions instead of Edge Middlewares (#4713)
* Don't use middleware

* changeset

* breaking change
2022-09-12 14:40:48 -04:00
Matthew Phillips
0dba3b6f3f
Make error handling more resilient in the dev server (#4723)
* Make error handling more resilient in the dev server

* Better approach

* Add a changeset
2022-09-12 14:40:31 -04:00