Skip to content
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

Update to latest #1

Merged
merged 325 commits into from
Jan 19, 2024
Merged

Update to latest #1

merged 325 commits into from
Jan 19, 2024

Conversation

mcgear
Copy link

@mcgear mcgear commented Jan 19, 2024

No description provided.

mbhrznr and others added 30 commits September 18, 2023 17:10
This PR changes CI to include the latest stable version of Deno,
alongside canary. This is important for picking up bugs in canary. This
seems like a reasonable thing to have for overall stability.

Possible prerequisite for #1819
These changes aim to improve the clarity and understandability of the
Deno KV OAuth plugin. It also updates to use the latest version of the
module.
Co-authored-by: Marvin Hagemeister <marvinhagemeister50@gmail.com>
Switched `update.ts` to use Deno fmt command on `deno.json` so it
respects the `deno.json` `fmt` configuration. Tested with 4 space
indentation.
CAYdenberg and others added 29 commits December 11, 2023 18:14
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
fix undefined var error.
Fixes #2184

Is there any reason for this not being `JSON.stringify({ ... that object
... })` and avoid a lat of escaping?
This change replaces the use of the Standard Library's `dotenv.load()`
with the native `--env` CLI flag.

The benefits include:
* One less dependency
* More obvious consumption of the `.env` file in the CLI output
Reverts #2204

The `--env` flag cannot be used by default because it fails when no
`.env` file is present. Therefore this PR accidentally introduced a
breaking change.
closes #2190

Marvin, I noticed that adding the fix
[here](https://github.com/denoland/fresh/blob/a8a43ff0d4ed7ae9958a09f37ce8dadf219f76e1/www/components/Header.tsx#L41)
did not resolve the issue. I see the docs say `Partials are enabled by
adding a f-client-nav attribute to an HTML element` -- is it expected
that adding `f-client-nav={false}` to a component does not automatically
apply it to html element children?
Currently, the [Carousel component](https://fresh.deno.dev/components)
only shows "slide four" without moving to other slides.
This PR will fix that issue.
By moving folks from `twind` over to the `tailwind` plugin we have
traded support questions about "how to get twind autocompletion
working?" with "my styles are not showing up in automatic mode". The
tailwind plugin has a hard requirement on having a build step. We have
documented this at various places and have a guide on how to set
everything up, but it's much better if we float those steps from Fresh
itself when we detect this.

With this PR we will prepare a `.github/workflows/deploy.yml` file
already where the user only needs to swap out the project name.

When Fresh is started in production mode, the tailwind plugin is active
and no snapshot files were loaded, then we print a helpful hint to the
console:

```sh
No pre-compiled tailwind styles found.

Did you forget to run "deno task build" prior to starting the production server?
```

When we are running inside Deno Deploy this PR goes one step further.
Since it is the first time many users might use Deno Deploy we'll also
show a simple page that shows how to finish the tailwind setup. I've
intentionally tried to not present this as a warning but rather as a
"finishing" step to avoid scaring users off. It's not the prettiest
page, but it's good enough for now.

<img width="892" alt="Screenshot 2024-01-09 at 23 41 27"
src="https://github.com/denoland/fresh/assets/1062408/9bf2a61b-5551-4d8e-bdf8-b498072f8e98">


Fixes #2223
Removes description of changing the port number with the deprecated
`port` property and updates with `server.port`.

![Screenshot 2024-01-12
190452](https://github.com/denoland/fresh/assets/138949169/84ac96b2-6c55-438d-8be1-22184f309a22)
This is not exploitable in practice unless a user maliciously crafts
serialized values in __FRSH_STATE, because `serializer()` never outputs
serialized representation that would be vulnerable to prototype
pollution. But hey, defense in depth.
As outlined in #2254 it was
possible to overwrite the script tag that is used by Fresh to pass
island props from the server to the client. This could be done by
injecting raw HTML via `dangerouslySetInnerHTML` and simply using the
same id that Fresh was using.

With this PR we generate a unique id per render that cannot be guessed
anymore. It's composed of `__FRSH_STATE_<uuid>`
Reverts #2259
Windows is failing with this change:
* my PR
https://github.com/denoland/fresh/actions/runs/7556810357/job/20574665605?pr=2261
* your PR
https://github.com/denoland/fresh/actions/runs/7543217433/job/20533721591
* the commit from merging your PR
https://github.com/denoland/fresh/actions/runs/7543221780/job/20533736560

```
Run deno task check:types
Task check:types deno check **/*.ts **/*.tsx
Error launching 'deno': The filename or extension is too long. (os error 206)
Error: Process completed with exit code 1.
```
@mcgear mcgear merged commit 27536cf into fathym-deno:main Jan 19, 2024
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment