This adds a short clarification how imported assets vs. static files get
handled now with Vite to the existing documentation for static files.
---------
Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Addresses the issue mentioned in
https://github.com/denoland/fresh/pull/3163#discussion_r2246708003.
The issue was that the `raw` markdown was being used for e.g. `## My
title`, thus the slug became `-my-title` instead of `my-title`. Slugs
were working correctly for `codespan` in headers, e.g. ``## `someCode`
``.
I decided to hard error if unexpected heading syntax is used over
sluggifying unexpected content (can become super weird otherwise, e.g.
`## <button ...>My heading</button>`). I can revert to fallbacking to
`raw` if preferred, but perhaps with at least trimming leading `-` just
in case.
Follow-up from #3162.
This PR does various tweaks, mostly related to code blocks.
- Adds missing titles to code blocks, and updates titles to be more
consistent
- Adds filenames to most ` ```tsx` blocks with e.g. `main.ts`, `dev.ts`
or a suitable example (e.g. `routes/greeting.tsx`) based on the code
- Adds filenames to ` ```diff` blocks if there's a relevant file, to
make the icon e.g. TS over Diff icon
- Code blocks with Fresh code (e.g. interfaces) uses ` ```tsx fresh 🍋`
- Changes most ` ```sh` blocks with example terminal commands to ` ```sh
Terminal`
- Updates ` ```txt Project Structure` or ` ```diff Project Structure`
blocks to be more consistent
- Changes `sh` or `txt` to `txt-files` which improves highlighting and
makes icon consistent
- Renames `<project dir>` to `<project root>` to match builder `root`
option terminology
- Adds `<project root>` root folder to most/all overview folder
overviews
- Makes the structure blocks more consistently displayed
- Tried to make some "bare" examples more complete
## Comparison
Here's a small curated set of before/after changes.
### Deployment
- `deno` highlighted in terminal commands
- `.gitignore` syntax highlighting works without using `sh` as language
<img width="1641" height="1009" alt="image"
src="https://github.com/user-attachments/assets/170cf833-1f6a-4b0d-8d2d-a081bc28a967"
/>
### File routing
Updated icon, comments same as before, but root and hierarchy have new
colors (`operator`/`function`).
<img width="1647" height="588" alt="image"
src="https://github.com/user-attachments/assets/f28db51b-4bee-45e4-be1c-e137a6d3ae3d"
/>
## Problem:
The problem was reproduced as described in #3002. Chrome DevTools shows
the following error:
props.js:137 Uncaught (in promise) InvalidCharacterError: Failed to
execute 'setAttribute' on 'Element': 'docs-content""' is not a valid
attribute name.
at j (props.js:137:8)
at V (index.js:528:5)
at O (index.js:326:28)
at I (children.js:97:16)
at V (index.js:547:4)
at O (index.js:326:28)
at I (children.js:97:16)
at V (index.js:547:4)
at O (index.js:326:28)
at I (children.js:97:16)
## Solution:
The issue was resolved by removing the double quotes around docs-content
in the Markdown image description. After this change, the application
resumed normal operation.
## Test:
Deno task ok and local env check
## Close:
close#3002
This commit updates several links which are outdated and now redirect to
different URLs on the updated Deno website and documentation.
There are a few dozen instances of URLs starting with
`https:://deno.land/x` and `https:://deno.land/std`. I left these alone
since they are dependencies. Would it make sense to update these from
the versions hosted at `deno.land` to their JSR equivalents, since that
is the new and preferred location of the Deno Standard Library packages
as well as other JavaScript/TypeScript packages used by Deno projects?
For example, the latest version of the Deno Standard Library is now
hosted at `https://jsr.io/@std` instead of `https://deno.land/std`.

---------
Co-authored-by: Marvin Hagemeister <hello@marvinh.dev>
Tackling - https://github.com/denoland/fresh/issues/2546
Basically just inlined the old reference file and removed the islands
and app builder to make it a bit more streamlined.
Could make the example more dry but I'm not working from my normal dev
environment.
After reading the discussion at #2369, this PR introduces a small
addition to the docs which highlights how you can use server components
within islands.
This, coupled with the existing docs, should hopefully give people
enough of an example to understand that islands provide the
interactivity layer, and that server components within them can be
hydrated and made interactive too.
Closes#2369
This adds in the information regarding co-location of islands and
components from [this blog
post](https://deno.com/blog/fresh-1.4#colocated-islands-components-and-more)
into the main documentation.
A lot of the text is pulled directly from the blog post, but I'm happy
to edit it if need be.
Closes#2305
I tested the change in my own repo, the warning on github disapears for
the "actions/checkout" action.
It is still there for the denoland/setup-deno action, but an upgrade PR
is already ongoing for this action, see:
https://github.com/denoland/setup-deno/pull/56