Commit graph

1528 commits

Author SHA1 Message Date
Matthew Phillips
500acb3c11
Throw when using Response.redirect from SSG site (#5116)
* Throw when using Response.redirect from SSG site

* Adding a changeset
2022-10-18 16:09:38 -04:00
Fred K. Bot
4c1ffef3e4
[ci] release (#5078)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2022-10-18 14:26:00 -04:00
Matthew Phillips
5c0c6e1ac6
Mark @astrojs/node to be noExternal (#5114)
* Mark @astrojs/node to be noExternal

* Adding a changeset
2022-10-18 11:47:18 -04:00
Daniel
5923dd77c1
adding cookies to api route response [simple result] (#5060)
* adding cookies to the an api route response, also when returning a simple result

* in dev server, convert a simple endpoint result into a response object

Co-authored-by: AirBorne04 <unknown>
Co-authored-by: AirBorne04 <>
Co-authored-by: Matthew Phillips <matthew@skypack.dev>
2022-10-18 09:52:49 -04:00
Josh Kramer
f684e9d361
Implicit element types (#5098)
* Separate arbitrary intrinsic element definition

* Create changeset
2022-10-18 10:23:48 -03:00
Rishi Raj Jain
df4d84610a
Fix port env in standalone mode (#5111) 2022-10-18 15:31:21 +08:00
Bjorn Lu
ef0c543163
Support spread parameters for server endpoints (#5106) 2022-10-18 13:16:24 +08:00
Bjorn Lu
0edfdd3259
Ensure CLI flags override function-style server config (#5110) 2022-10-18 13:10:16 +08:00
Erika
ce01225a70
Fix types not working properly when using moduleResolution: 'node16' (#5108)
* Fix imports failling under `moduleResolution: node16`

* Add changeset

* Revert comment about Vite 4
2022-10-17 11:29:39 -03:00
Juan Martín Seery
cd25abae59
feat(vercel): includeFiles and excludeFiles (#5085)
* refactor + include/excludeFiles

* Changeset

* Updated README.md

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

* Missing .js

Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
2022-10-14 17:19:35 -03:00
Juan Martín Seery
f8198d2502
feat(vercel): Edge improvements (#5086)
* Added error on "output" == "static"

* Minify output

* Changeset
2022-10-14 17:17:13 -03:00
Erika
ddfbef5acb
Fix astro add adding lines from extended configurations (#5095) 2022-10-14 15:16:41 -03:00
Bjorn Lu
0173c2b2df
Suppress warnings for solidjs dependency crawling (#5089) 2022-10-14 17:51:42 +08:00
Juan Martín Seery
49a8d18b49
fix: pnpm install command on astro add (#5087) 2022-10-14 15:08:51 +08:00
Matthew Phillips
90b715d5c8
Fixes JSX usage of slots with dashes in their name (#5080)
* Fixes JSX usage of slots with dashes in their name

* Adding a changeset
2022-10-13 17:40:17 -04:00
Matthew Phillips
5fb7c9383a
Compat with Astro < 1.5 (#5082)
* Compat with Astro < 1.5

* Adding a changeset
2022-10-13 16:10:48 -04:00
Nate Moore
d25f54cb93
[Vue] add support for appEntrypoint (#5075)
* feat(vue): add support for appEntrypoint

* chore: add changeset

* test(vue): add tests for app entrypoint

* docs(vue): update README to include app entrypoint

* fix(vue): prefer resolvedVirtualModuleId

Co-authored-by: Nate Moore <nate@astro.build>
2022-10-13 14:15:57 -05:00
Erika
6f9a88b31b
Fix aliases from jsconfig.json not being picked up anymore (#5076)
* Fix aliases from jsconfig.json not being picked up anymore

* Add changeset
2022-10-13 15:39:32 -03:00
Fred K. Bot
81d57f2638
[ci] release (#5046)
* [ci] release

* Update packages/integrations/node/CHANGELOG.md

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

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Matthew Phillips <matthew@skypack.dev>
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
2022-10-13 12:29:24 -04:00
Bjorn Lu
3918787cb9
Support relative protocol image URL (#5072)
* Support relative protocol image URL

* Fix test

* Actually fix test
2022-10-13 11:59:38 -04:00
Bjorn Lu
93f72f90bc
Fix image external config in build (#5073) 2022-10-13 11:16:08 -04:00
Matthew Phillips
e55af8a232
Node.js standalone mode + support for astro preview (#5056)
* wip

* Deprecate buildConfig and move to config.build

* Implement the standalone server

* Stay backwards compat

* Add changesets

* correctly merge URLs

* Get config earlier

* update node tests

* Return the preview server

* update remaining tests

* swap usage and config ordering

* Update packages/astro/src/@types/astro.ts

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

* Update .changeset/metal-pumas-walk.md

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

* Update .changeset/metal-pumas-walk.md

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

* Update .changeset/stupid-points-refuse.md

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

* Update .changeset/stupid-points-refuse.md

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

* Link to build.server config

Co-authored-by: Fred K. Schott <fkschott@gmail.com>
Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca>
2022-10-12 17:25:51 -04:00
Bjorn Lu
ebd364e392
Add new fields to API route context (#4986)
* Add new fields to API route context

* Add props and redirect

* Pass custom redirect status code

* Correctly pass props in api routes

* Add better docs

* Add test

* Fix build

* Add constants file

* Add links to jsdoc

* Workaround lint issue

* Thanks Chris

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

* Missed one doc change

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

* Add more detail to the changesets

* Strict redirect status type

Co-authored-by: Chris Swithinbank <swithinbank@gmail.com>
Co-authored-by: Matthew Phillips <matthew@skypack.dev>
2022-10-12 17:03:49 -04:00
Erika
0ea6187f95
Added support for updating tsconfig.json when using astro add (#4959)
* Added support for updating tsconfig.json when using astro add

* Refactor

* Remove unneeded change

* Fix build failling due to type difference

* Extend changeset description
2022-10-12 15:11:25 -03:00
Juan Martín Seery
a5e3ecc803
feat: restart dev server when tsconfig and tailwind config changes (#4947)
* First run

* Works with tailwind!

* Added TSConfig to watchlist

* Changeset

* Fix eslint

* Renamed `isConfigReload` --> `isRestart` and `injectWatchTarget` --> `addWatchFile`

* Refactored watchTargets to watchFiles

* Refactor createSettings

* addWatchFile now accepts URL

* Fix getViteConfig

* Expanded description of the change

Co-authored-by: Matthew Phillips <matthew@skypack.dev>
2022-10-12 11:36:33 -04:00
Bjorn Lu
f7fcdfe621
Support solidjs libraries (#5059) 2022-10-12 21:29:26 +08:00
Matthew Phillips
1e27992437
Update the Astro.cookies.set types to receive boolean and numbers (#5047) 2022-10-12 08:31:55 -04:00
Bjorn Lu
baf88ee9e5
Skip JSX tagging for export statements with source (#5057) 2022-10-12 08:25:54 -04:00
Matthew Phillips
0f2a88ba5c
Allow class to be passed into Svelte islands (#5045)
* Allow class to be passed into svelte component

* Adding a changeset
2022-10-10 15:19:18 -04:00
Juan Martín Seery
44ea0c6d94
chore: Upgrade Astro compiler to 0.27.1 (#5044) 2022-10-10 14:50:08 -04:00
Fred K. Bot
0ab0d8d863
[ci] release (#5019)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2022-10-10 11:44:22 -04:00
Juan Martín Seery
c1f991408b
fix(vercel): now works with monorepos (#5033)
* Upgraded nft

* Handle monorepo better

* Changeset

* Fixed common ancestor

* Fixed outdir
2022-10-10 11:37:03 -04:00
Bjorn Lu
2d9d422167
Support strict dependency install for image integration (#5034) 2022-10-10 11:35:48 -04:00
Matthew Phillips
38fdb4ca6f
Shorter CSS naming algorithm (#5036)
* Shorter CSS naming algorithm

* Adding a changeset

* Update packages/astro/src/core/build/vite-plugin-css.ts

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

Co-authored-by: Bjorn Lu <bjornlu.dev@gmail.com>
2022-10-10 11:05:28 -04:00
Daniel
d7bfb144ba
fixing multiple doctype injections in single file (#5035)
* fixing multiple doctype injections in single file

* adding changeset

Co-authored-by: C5341616 <C5341616@sap.com>
2022-10-10 09:02:20 -04:00
Matthew Phillips
b1964e9e1b
Revert "Revert preact signals support (#4843)" (#5015)
This reverts commit 25a5b9a89a.
2022-10-10 09:01:15 -04:00
Matthew Phillips
062335dbf7
Fix remote images in SSG mode (#5021) 2022-10-07 17:08:15 -04:00
Matthew Phillips
6efeaeb39e
Fix suppot for mui (#5016) 2022-10-07 15:54:25 -04:00
Fred K. Bot
4e8625fbfb
[ci] release (#5014)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2022-10-07 10:34:13 -04:00
Matthew Phillips
ffbe4e71e3
Move astro/config into src and typecheck (#5013)
* Move astro/config into src and typecheck

* Adding a changeset
2022-10-07 10:30:08 -04:00
Oskar Baumann
92b27e9c92
[@astrojs/prefetch]: Prevent prefetching current page (#5009)
* Check that removal of url.hash breaks no tests

* test if status-quo is as expected

* Adapt tests to fail

* Adapt the shouldPreload function to skip same path

* Add changeset
2022-10-07 10:13:51 -04:00
Fred K. Bot
778b915525
[ci] release (#4976)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2022-10-06 13:47:10 -04:00
Oskar Baumann
a2b66c7549
[@astrojs/image]: Fix <Picture /> component with query string (#4997)
* remove query params from file extension

* Revert changes to make change as small as possible

* moving the removeQueryParam check to basename()

* chore: adding a changeset

* adding SSR test coverage for new picture test cases

Co-authored-by: Tony Sullivan <tony.f.sullivan@outlook.com>
2022-10-06 15:53:11 +00:00
João Araújo
50a397c4ba
Update @builder.io/partytown dependency (#4989) 2022-10-06 10:33:01 -04:00
Daniel
2dc582ac5e
adjusting cloudflare adapter and solid ssr to work together (#4888)
* adjusting cloudflare adapter (respecting user config)
define better solid ssr config

* only inline the framework

this needs to happen for worker build in order to have the correct build mode for the framework, which needs the nodejs no matter if it is for node or the browser.

Co-authored-by: AirBorne04 <daniel@floatingpixels.com>
2022-10-06 10:28:47 -04:00
Matthew Phillips
1f890b3363
Yield out potentional slot instructions when rendering dynamic tags (#4981)
* Yield out potentional slot instructions when rendering dynamic tags

* Adding a changeset

* yield instead of return

* Handle the fact that renderComponent returns an iterable

* Only yield out html once
2022-10-05 16:30:43 -04:00
Matthew Phillips
8f9791d840
Upgrade Astro compiler to 0.26.0 (#4990)
* Upgrade Astro compiler

* Add changeset
2022-10-05 16:29:30 -04:00
Bjorn Lu
a6bb2694b4
Refactor hydration path handling (#4918)
* Refactor hydration path handling

* Remove old code

* Fix jsx strip

* Postprocess fix

* Handle jsx to tsx stuff

* Skip bigint tests

* Fix deno

* Try fix windows

* Fix windows

* Add more comments
2022-10-04 12:59:35 -04:00
董雨航
61d26f3352
fix: import.meta.env.BASE_URL will be '/' in client loaded component on dev mode (#4886) 2022-10-04 12:57:35 -04:00
Calvin Liang
37cb2fc02a
fix object styles not escaped (#4887)
* fix object styles not escaped

* fix `shouldEscape` not passed down

* add tests

* fix package name

* fix pnpm-lock

* add changeset
2022-10-04 12:56:11 -04:00