This is a autopost bolg frinds we are trying to all latest sports,news,all new update provide for you
Thursday, September 1, 2022
Show HN: Pith language. JavaScript with a little bit of Python syntax https://ift.tt/83KQ1aE
Show HN: Pith language. JavaScript with a little bit of Python syntax I've been writing a lot of JavaScript and Python lately. I like Python's syntax, so I created a language called Pith that's JS with some Python-like syntax (but without trailing colons). It's not a full compiler. It really just does search-and-replace, but I find it fun and useful in spite of some sharp edges. I use it on my smartphone to write and run short programs. Here's an example using the HN API: max = 6 ids = await getApi('topstories') for id in ids.slice(0, max) getItem(id) async def getItem(id) const d = document.createElement('div') results.appendChild(d) d.style = 'padding-bottom: 1em;' i = await getApi('item/' + id) ? i.title, '|', i.score u = '//news.ycombinator.com/item?id=' d.innerHTML = i.title.link(u + id) async def getApi(path) u = '//hacker-news.firebaseio.com/v0/' return getJson(u + path + '.json') https://ift.tt/XBnuHWS September 2, 2022 at 12:17AM
Subscribe to:
Post Comments (Atom)
Show HN: TBD, a Mac-native CLI-forward coding agent multiplexer https://ift.tt/2I3TKB7
Show HN: TBD, a Mac-native CLI-forward coding agent multiplexer Inspired by Conductor, dmux, claude-squad, agent-deck, and Git Tower ## What...
-
Show HN: When is the next Caltrain? (minimal webapp) I was frustrated with the existing caltrain websites / apps, so I made a super minimali...
-
Show HN: I built Dirac, Hash Anchored AST native coding agent, costs -64.8 pct Fully open source, a hard fork of cline. Full evals on the gi...
-
Show HN: A directory of 800 free APIs, no auth required Explore reliable free APIs for developers — ideal for web and software development, ...
No comments:
Post a Comment