HNHacker News
TopNewBestAskShowJobs

aabbcc1241

852 karma · joined December 3, 2014

[ my public key: https://keybase.io/beenotung; my proof: https://keybase.io/beenotung/sigs/CLB3i0aTqbycgeZ3_nslWRZkfvmr0-lJ-ym9Hqkq2Nk ]
submissionscomments
aabbcc1241··on VanJS – A no-JSX framework based on vanilla JavaScript
The syntax looks similar to dom-proxy [1]

[1] https://github.com/beenotung/dom-proxy

aabbcc1241··on Catalyst – Tailwind CSS Application UI Kit
The download count may not reflect the adoption rate. It is largely affected by CI/CD.
aabbcc1241··on Semi-Automatic Dark Mode for most website
You can drop this script on your website then it'll likely just work

    <script type="module" src="https://cdn.jsdelivr.net/npm/@bufferhead/nightowl@0.0.12/dist/nightowl.js"></script>
aabbcc1241··on Free Public Blockchains?
You may have a look at zeronet and ipfs, they're not blockchain but maybe interesting to you
aabbcc1241··on Ask HN: How to do literal web searches after Google destroyed the “ ” feature?
I use a local hosted web spider and search engine

It only index the pages that I've viewed so it's not spammed by SEO junks

https://github.com/beenotung/personal-search-engine

aabbcc1241··on Show HN: Open-source Postman alternative with type safety
You may try cast.ts. It is similar to zod but the parser has .type property which expose the typescript type of the validator, and .sampleValue property which expose a sample value. So you can access the metadata at runtime, which can be reused by other tools like yours.
aabbcc1241··on Show HN: Open-source Postman alternative with type safety
Maybe you want a Typescript SDK more than a HTTP endpoint.
aabbcc1241··on TypeScript is surprisingly ok for compilers
the flexibility you describe seems to be coming from lisp (schema) that javascript was designed on top of initially
aabbcc1241··on Don’t build a general purpose API to power your own front end (2021)
previous discussion: https://news.ycombinator.com/item?id=28511570
aabbcc1241··on Node.js 20.6.0 will include built-in support for .env files
You can use validator like populate-env[1] to check for missing env variables

[1] https://www.npmjs.com/package/populate-env

aabbcc1241··on Things you forgot (or never knew) because of React
The render function is a pure function returning jsx based on the input, not invoking any stateful operation like "functional hook".

So this style of code is fine in react

aabbcc1241··on Things you forgot (or never knew) because of React
I want to add more on the “other staff you should try” list:

- phoenix liveview / ts-liveview / hotwire

- htmx

- clojure

- cycle.js

- dom-proxy

- data-template

aabbcc1241··on tRPC – Build and consume typesafe APIs without schemas or code generation
The title is misleading, there is schema (defined with zod in specific)
aabbcc1241··on Server-Driven UI
The approach mentioned in this article is more abstract than SSR and liveview, making it adaptable to both webapp and mobile app
aabbcc1241··on Why I Hate Frameworks (2005)
> I can't imagine things being much simpler than this

Imagine simplifying the last example without useState and setState, nor useEffet and depList

aabbcc1241··on JavaScript Gom Jabbar
The setup can be automated with bash script or "npm init <template-name>" or unzip from a template archive
aabbcc1241··on I booted Linux 293k times in 21 hours
Do you mean hacker news as "this site"? HN seems to be server side rendered, so it should display well without Javascript.
aabbcc1241··on Google no longer automatically indexes websites?
An alternative web search architecture, is collaborative sharing the site we made or visit.

I made a self hosted spider that only index sites that I've visited and search engine with "and" "or" logics.

Thinking to make it a federated search engine by allow each user whitelist domains that are not sensitive to search with the peer. And users can follow/block other users explicitly to avoid spam.

https://github.com/beenotung/personal-search-engine

aabbcc1241··on That people produce HTML with string templates is telling us something
You can write custom jsx function and let typescript call your function instead of react's.

Your custom jsx function can return data in reusable format, that is passed to different functions for difference use case.

ts-liveview is using this approach to use jsx for both server-side rendering and compact over-the-wire updates

aabbcc1241··on Ts-morph – programmatically manipulate TypeScript source code with TypeScript
Yes, the demo in readme shows you to create/edit source code in type-safe manner
aabbcc1241··on Show HN: YouTube Full Text Search – Search all of a channel from the commandline
Youglish [1] is a website that allow you to search video with timestamp by transcript text

[1] https://youglish.com/

aabbcc1241··on Erlang/OTP 26 Highlights
That's interesting!

I think Typescript would be "easier" for a larger group of developers to hook on

aabbcc1241··on Erlang/OTP 26 Highlights
Maybe a transpiler and type checker that convert typescript into erlang can help to drive the adoption
aabbcc1241··on Building a front end framework – Reactivity, composability with no dependencies
dom-proxy is the most recent work, I'm glad it stands out to you
aabbcc1241··on Building a front end framework – Reactivity, composability with no dependencies
Wish you'll keep up and see more adoption over time :)
aabbcc1241··on Building a front end framework – Reactivity, composability with no dependencies
I made a similar library [1] using data-* attributes. It also supports nesting, looping and conditions. For event handling, I use function in object (a.k.a. method) while you support writing them inline.

Your way to support inline logic in the text and style is interesting.

[1] https://github.com/beenotung/data-template

aabbcc1241··on Building a front end framework – Reactivity, composability with no dependencies
Would you also add these js library to the list? They don't require build step as well.

https://github.com/beenotung/html-template-lite

https://github.com/beenotung/data-template

https://github.com/beenotung/dom-proxy

aabbcc1241··on Building a front end framework – Reactivity, composability with no dependencies
I'm experiencing the trade off between simplicity and expressiveness for a lightweight frontend library that doesn't involve VDOM.

On one hand, a library [1] can be very concise (update dom from object, with looping and nesting supported).

On another hand, a library [2] can be very flexible and reactive (update dom from dom events).

However, when double-binding (a.k.a. bi-directional binding) is required (update dom from object and update object from dom), it seems more complex than I would consider it lightweight.

When double-binding is preferred, I'd rather go for angular / vue. Still exploring alternatives.

[1] https://github.com/beenotung/data-template

[2] https://github.com/beenotung/dom-proxy

aabbcc1241··on Jive – an architecture for semi-native apps
This concept is similar to liveview, with suggestion to run the backend in local / remote environment
aabbcc1241··on Show HN: DOM-proxy: declarative UI with automatic dependecy tracking
Develop lightweight and declarative UI with automatic dependecy tracking without boilerplate code, VDOM, nor compiler.

The concept is to use Proxy API to wrap the DOM object, and auto keep track of the dependency of some reactive statements.

The DOM event listener is auto setup to trigger re-run when the UI is updated by user, and the proxy setter triggers re-run when other part of code is updating the reactive statement's dependency.

The current implementation is a lightweight library with inferred Typescript types.

This design could be extended to support server side rendering as well.

← PreviousPage 3 of 21Next →