Hacker News new | past | comments | ask | show | jobs | submit login
Amber: Smalltalk for the Web (amber-lang.net)
118 points by lunarcave on Jan 4, 2024 | hide | past | favorite | 30 comments



Related:

Amber Smalltalk - https://news.ycombinator.com/item?id=26128607 - Feb 2021 (12 comments)

Amber – Smalltalk in the Browser - https://news.ycombinator.com/item?id=22425626 - Feb 2020 (1 comment)

Learn Smalltalk with ProfStef - https://news.ycombinator.com/item?id=17940152 - Sept 2018 (6 comments)

Amber Smalltalk - https://news.ycombinator.com/item?id=13112207 - Dec 2016 (48 comments)

Amber: A new language and live environment made for the web - https://news.ycombinator.com/item?id=11299547 - March 2016 (1 comment)

Smalltalk runtime in the browser - https://news.ycombinator.com/item?id=6216539 - Aug 2013 (33 comments)

Amber Smalltalk 0.10 released - https://news.ycombinator.com/item?id=5369682 - March 2013 (15 comments)

Learn Smalltalk in the browser - https://news.ycombinator.com/item?id=2996510 - Sept 2011 (2 comments)

Amber - Smalltalk on JavaScript runtime - https://news.ycombinator.com/item?id=2995689 - Sept 2011 (1 comment)


I used to use it daily back in 2013.

Even put together flow [1] a stack based on it because the workflow with Pharo and Mapless [2] felt so nice.

And blogged about it:

Flow - A living full-stack ‎framework for the web - https://medium.com/@sebastiansastre/flow-a-living-full-stack...

Improving the Amber Experience - Some small steps to improve the productivity and overall experience of developing with Amber Smalltalk - https://medium.com/@sebastiansastre/improving-the-amber-expe...

Flow demoed at Smalltalks2014 - https://medium.com/@sebastiansastre/flow-demoed-at-smalltalk...

Upgrading to flow 0.2 - https://medium.com/@sebastiansastre/upgrading-to-flow-0-2-d4...

[1] https://github.com/flow-stack/flow

[2] https://github.com/sebastianconcept/Mapless


Out of curiosity, why did you stop using it daily?


My plan was to have something strategic regarding to the productivity of the smalltalker in terms of web applications that can deliver the UX of a single page application.

Here is a talk with more spirit than skill back from 2014 trying to promote that mission https://www.youtube.com/watch?v=iumCpezWzkU

At the time I was focused in a Seaside based SaaS that I started in 2009 https://www.youtube.com/watch?v=7Z29q5PUoJs

Although that SaaS had very low churn and very long LTV and low CAC, I failed to raise money to grow it and I've failed to find the right growth guy that could help and shutdown in 2015. My bet was to use that flow stack to make this SaaS next big upgrade to be a Single Page Application done with Amber in the frontend but didn't go well due to these non-technical issues.

Then Angular was eating the web world and the React tsunami was just started.

It's funny to see that now there is a come back to SSR.


Couldn’t easily find any code samples so left it last time this came up. Would appreciate a pointer? Thanks


i love smalltalk, but i mainly do web development, and i was curious to do frontend development in smalltalk, so amber looked interesting. but i could not see how to do frontend only development. i am not interested in fullstack solutions because they only work for greenfield projects. i mostly build frontends for existing backends with a REST API or similar.

existing smalltalk webframeworks are either backend or fullstack, and made no sense for me to use inside amber.

an amber frontend framework would essentially be a GUI toolkit that uses html/css templates to design the UI, then smalltalk to fill in the logic with fetch calls to exchange data with arbitrary backends.


> i am not interested in fullstack solutions because they only work for greenfield projects. i mostly build frontends for existing backends with a REST API or similar.

There are probably other reasons to avoid a full stack framework, but this isn't one—there's nothing to stop you from making the backend just a proxy to the existing API.

Aside from that, Amber is entirely client-side from what I can see. The Amber server is the equivalent of the Webpack or Vite dev servers, just used during the development process. It looks like Amber compiles to plain JS that runs directly in the browser.


yes, amber is entirely clientside. that is what makes it interesting. but the smalltalk web frameworks are mostly backend frameworks designed to run in pharo or squeak, which means they feel way to bulky and not suited for an SPA web frontend were i want to dynamically update the DOM when data changes instead of generating a whole new page to send to the browser like traditional web frameworks.

there's nothing to stop you from making the backend just a proxy to the existing API

what is stopping me is that this forces me to run two backends and an additional layer of indirection.


Check out this lightweight intro, which touches on REST API communication: https://medium.com/smalltalk-talk/a-gentle-introduction-to-a...

It also shows how to integrate with external JavaScript libraries. The example they use is D3.

Here's part 2 of their article: https://medium.com/@richardeng/you-are-now-an-ambersmith-c25...

There are probably other tutorial that are more extensive.


i have actually looked into this at the time, but i could not figure out how to make it work with the frontend framework i was using. and i didn't find any more extensive tutorials either. it probably takes more familiarity with amber than i was able to get to make it work.

a tutorial to use amber with react or svelte for example would be great. (i don't work with either, but given that they are a,mong the most popular frameworks for the time being, it has the most likelihood at capturing some interest.)


You reminded me of back in the day when I really tried to make this fit some project:

https://ympbyc.github.io/LittleSmallscript/


that's neat. how far did you get using it?


I totally loved the idea at first. In practice it became kind of what CoffeeScript is to JavaScript, which is not a lot more than a syntactic preference that doesn't help you when you need to debug. Actually hurts you a little bit because that indirection forces you to become the cognitive mapping of their differences. You eventually can become a comfortable "Smalltalk" author in LitleSmallscript and a decently productive JavaScript debugger but at the end of the day it just became easier to be polyglot and not have it as barrier to share code with other devs when needed. So I didn't ended up using it for any project.


that makes sense. i have been using coffeescript, and i know what you mean. the main draw for a different syntax for me was readability as coffeescript had some advanced constructs that javascript didn't have, but since then javascript has caught up and so coffeescript no longer offers that much of a benefit that it once did.

in difference to coffeescript smalltalk at least offers the benefit of a syntax that is also usable elsewhere.


I think it was in 2016 that I've used CoffeeScript for one project for some months. With daily usage I ended up acquiring taste and ended up enjoying it.

For LittleSmallScript I knew the syntax taste will go to the roof. And you're making a great point, indeed parts of a program written with Smalltalk syntax would have a lot degree of reuse.


you can also check out Cuis Smalltalk, which includes be able to run in the browser using WASM

Prior discussion: https://news.ycombinator.com/item?id=38820742


this doesn't solve the problem. i am not looking for a smalltalk desktop that can run in a browser, but for a smalltalk based web gui toolkit that uses html/css for its interface.

to bring it to a point, i'd like to use smalltalk with a web framework the way i use typescript or coffeescript with angular or react


> Smalltalk stands head and shoulders above most other languages for clarity, conciseness, and human-friendliness.

Very cool. What if I want to read through printout of your smalltalk program?


No commits for a year? https://lolg.it/amber/amber Is it dead?


I think so. SqueakJS fills the space Amber used to occupy.


Is Squeak itself still an actively developed project? I hear much more about Pharo.


While it's slowed down in recent years, it's still active. Re: Pharo, that's just because they market it hard and don't give much (any?) credit back to Squeak which is what it was forked from. (and still shares more DNA with Squeak than the Pharo folks like to admit)


i would like to learn pharoh, but I can't seem to understand how to get started. It looks like one of those tools you need a video to understand.


You can start with the Pharo MOOC: https://mooc.pharo.org/

There's a tutorial to get the very basics of Smalltalk/Pharo called ProfStef. Here's an online version: https://amber-lang.net/learn.html

It has a built-in version on Pharo images as well.


Have you seen you have this track in Exercism?

https://exercism.org/tracks/pharo-smalltalk

And this if you want to feel not alone in the first steps:

https://www.youtube.com/watch?v=YQ-kAQWMMTQ


Thank you! Getting into it this new week.


When you start it, you get a first start wizard that allows you to start a tutorial


Glamorous toolkit docs/examples are a useful pharo intro.


It's actively developed. Pharo started as a fork of Squeak.


Squeak is certainly slow, but Cuis is moving at a good clip.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: