Live data from Hacker News

Fresh 1.1 – Automatic JSX, plugins, DevTools, and more

deno.com

21–30 of 57 posts

Re: Fresh 1.1 – Automatic JSX, plugins, DevTools, and more

#21
post #8

Great update! I wonder if Fresh plans to use Deno's (new) HTTP server[1]. Benchmarks for that look incredible (compared to Express). Off-topic but how does the video[2] under Preact Dev Tools look so sharp yet only weight 43KB? Edit: nevermind, the downloaded file's 2.9MB. Must be something up with Chrome's network tab. [1]: https://deno.com/blog/v1.25#new-experimental-http-server-api [2]: https://deno.com/fresh-1.1/…

https://deno.com/blog/fresh-1.1#experimental-denoserve-suppo... Just use --unstable to enable it.

You also need to pass a `experimentalDenoServe: true` option in the options bag passed to `start()` in your `main.ts` file.

I forgot to add this to the post initially. Have retroactively added it now :)

Re: Fresh 1.1 – Automatic JSX, plugins, DevTools, and more

#22

I've been writing a simple single page form app the past few days and I like Fresh a lot. I really appreciate the simplified project layout vs my last setup of a react app project nestled in a parent express project. It just makes the devops, if you would even called it that, of writing a one-person full stack app easier. Deno running TypeScript without a compile to JS adds to this. I'm happy to see the Preact Signal…

Thanks for the kind words!

Re: Fresh 1.1 – Automatic JSX, plugins, DevTools, and more

#23
I just ran this and got a bad cert error. How should I fix it?

deno run -A -r https://fresh.deno.dev my-project

Sending fatal alert BadCertificate error: error sending request for url (https://fresh.deno.dev/): error trying to connect: invalid peer certificate contents: invalid peer certificate: UnknownIssuer

Re: Fresh 1.1 – Automatic JSX, plugins, DevTools, and more

#24

I seriously cannot wrap around my head how in 2022 people really like JSX and all that X-in-JS crap, it's like people doesn't know about separation of concerns or clean code at all.

Separating which concerns?

I guess software is like your cutlery drawer. You want to keep your knives, forks and spoons separate.

Re: Fresh 1.1 – Automatic JSX, plugins, DevTools, and more

#25
post #12

I seriously cannot wrap around my head how in 2022 people really like JSX and all that X-in-JS crap, it's like people doesn't know about separation of concerns or clean code at all.

For almost anything more interactive than a static document, modularizing UI code primarily based on component boundaries makes a lot more sense than modularizing primarily based on markup / interactivity / styling boundaries.

Exactly, it comes from a bygone era when there was a clear separation between frontend developers (i.e. people that wrote markup, CSS, and jquery style JS) and backend developers (people that wrote PHP, ASP, java, etc. to spit out markup that frontend devs wrote). Nowadays everyone is basically full stack with specializations or focus in specific parts.

Re: Fresh 1.1 – Automatic JSX, plugins, DevTools, and more

#26

I've been writing a simple single page form app the past few days and I like Fresh a lot. I really appreciate the simplified project layout vs my last setup of a react app project nestled in a parent express project. It just makes the devops, if you would even called it that, of writing a one-person full stack app easier. Deno running TypeScript without a compile to JS adds to this. I'm happy to see the Preact Signal…

[deleted]

Re: Fresh 1.1 – Automatic JSX, plugins, DevTools, and more

#27

I just ran this and got a bad cert error. How should I fix it? deno run -A -r https://fresh.deno.dev my-project Sending fatal alert BadCertificate error: error sending request for url ( https://fresh.deno.dev/ ): error trying to connect: invalid peer certificate contents: invalid peer certificate: UnknownIssuer

Are you behind a corporate firewall? Can you set `DENO_TLS_CA_STORE=system` and try again?

Re: Fresh 1.1 – Automatic JSX, plugins, DevTools, and more

#28

Anybody here used Fresh for a non-toy project yet? Have anecdotal experiences to share?

Not exactly what you're looking for but in case helpful, I used Fresh/Deno/Deno Deploy for a toy project & have some takeaways that might apply more broadly:

- there's a bunch of mildly annoying paper cuts due to not running the full set of npm/JavaScript (yet?). I had to Google for and debug deno specific versions of libraries I wanted to use. Felt similar to trying to write Web Worker subset JS for Cloudflare Workers. Hope this improves. Though being able to address packages at import location by URL was neat.

- Deno Deploy was outrageously fast at deploying. It made updating the live site a joy compared to other FaaS stuff I've used

- I liked that I could process multiple domains on the same project (I was able to make 3 sites https://thisclowndoesnotexist.com https://thisbernerdoesnotexist.com and https://thisghostdoesnotexist.com live with their own domains within 5 mins or so each which was neat). Their https certificate tool was sometimes being rate limited so required a couple retries

- the deno runtime itself is fast as heck. I know bun goes even further but dang, stuff installs and executes so quickly it feels broken at first

- the Deno Deploy edge is quite fast, and there seems to be no major cold start issues. See https://bench.t3.gg/ for some comparisons (I found it fun use `fly curl` to test global response times)

Re: Fresh 1.1 – Automatic JSX, plugins, DevTools, and more

#29

I seriously cannot wrap around my head how in 2022 people really like JSX and all that X-in-JS crap, it's like people doesn't know about separation of concerns or clean code at all.

Seperation of languages != seperation of concerns

One could argue the adoption of JSX actually allows for better seperation and cleaner code as you can group all the necessary pieces of your component together, and use components declaratively without introducing some DSL seen in some frameworks like Vue, Angular etc.

Re: Fresh 1.1 – Automatic JSX, plugins, DevTools, and more

#30

I just ran this and got a bad cert error. How should I fix it? deno run -A -r https://fresh.deno.dev my-project Sending fatal alert BadCertificate error: error sending request for url ( https://fresh.deno.dev/ ): error trying to connect: invalid peer certificate contents: invalid peer certificate: UnknownIssuer

Are you behind a corporate firewall? Can you set `DENO_TLS_CA_STORE=system` and try again?

Is deno using a custom cert store by default?

---

https://deno.com/blog/v1.13#use-system-certificate-store-for...

Post reply on HN