skip to content
Video cover art for Val Town with Steve Krouse
Video

Val Town with Steve Krouse

Steve Krouse demos Val Town, a social JavaScript platform for writing, sharing, and deploying server-side functions as easily as posting a tweet.

Open .md

Episode Description

Steve Krouse demos Val Town, a social JavaScript platform for writing, sharing, and deploying server-side functions as easily as posting a tweet.

Episode Summary

Steve Krouse joins JavaScript Jam to introduce Val Town, a platform he describes as a blend of GitHub Gists and AWS Lambda with social networking features baked in. He traces his path from computer science education and Brett Victor fandom through his Future of Coding podcast and a failed WebAssembly project, eventually landing on Val Town after a reverse pitch from investor Dan Levine at Accel. The core idea is that code and its runtime should live together at a URL, making it as easy to share a running function as it is to share a tweet. During the live demo, Steve walks through persistent JavaScript values, the social import system that lets you reference another user's code like an @ mention, console email notifications, scheduled functions, and Express-style HTTP endpoints that can return HTML or render React components. The hosts attempt to wire up a Twitter alert for JavaScript Jam mentions, which surfaces real-time friction with the Twitter API but also showcases how Val Town handles secrets, API integrations, and composable public functions. Steve closes by outlining three priorities: moving away from proprietary syntax toward web-standard HTTPS imports, making embedded vals work seamlessly in documentation and READMEs, and turning individual val links into shareable web primitives that can go viral the way GitHub repos do.

Chapters

00:00:00 - Introductions and What Is Val Town

Scott and Anthony welcome Steve Krouse to JavaScript Jam, where he gives his elevator pitch for Val Town: a social JavaScript platform that lets you write server-side functions in a browser text box, deploy them instantly, and share them via URL. Anthony compares it to a mashup of Netlify and Twitter, and the group discusses how it resembles GitHub Gists crossed with AWS Lambda, with an NPM-like social import system where referencing another user's code is as simple as tagging them.

Steve explains that Val Town's import model uses a Twitter-style handle syntax, so pulling in someone else's exported value is a one-liner. The conversation touches on why GitHub never built this despite having Gists, and how the platform occupies a unique space between toy demo environments and full professional workflows, optimizing first for hobbyists and personal use cases before scaling toward heavier production needs.

00:03:07 - Steve's Background and Brett Victor Inspiration

Steve shares his origin story, starting with a middle school after-school coding program that sparked his interest in programming education and eventually led him to the work of Brett Victor and Seymour Papert. He describes spending years as a self-described professional Brett Victor fanboy, reading papers, climbing intellectual lineage trees, and hosting the Future of Coding podcast where he interviewed figures like Pete Hunt about the creation of React.

Anthony highlights the value of podcasts as oral history, noting that Pete Hunt revealed previously unpublished details about React's early days on Steve's show, including backstory about David Nolan's influential post connecting React and ClojureScript. The conversation briefly detours into AI-powered language learning tools and mock interviews with historical figures before returning to Steve's podcast favorites, including an interview with Lane from Coda about democratizing programming.

00:11:23 - The Origin Story of Val Town

Steve recounts the prototypes and research that preceded Val Town, including his whole code catalog reviewing tools like Glitch, Replit, and Zapier, and a failed WebAssembly frontend framework called Zaplib that couldn't consistently outperform vanilla JavaScript. The key turning point came when investor Dan Levine at Accel pitched Steve on the idea rather than the other way around, describing a vision for a CodePen-like platform for the backend where code and runtime ship together at a URL.

Levine's framing centered on the problem of dead code scattered across Stack Overflow and documentation pages, arguing that a web primitive for runnable, portable, forkable server-side code would transform how developers share and collaborate. Steve found the reverse pitch compelling enough to build Val Town around it, and the group reflects on how the platform tries to balance simplicity for beginners with enough capability to handle real integrations and workflows.

00:17:13 - Live Demo: Persistent State and Console Email

Steve shares his screen and walks through Val Town's interface, showing folders of vals, the social import system, and how persistent JavaScript values work as lightweight state storage backed by Postgres. He creates a new public variable and a function that appends messages to it, demonstrating how anyone can call a public function via API to modify state while only the owner retains write access.

Anthony has an aha moment, calling it a Python notebook for JavaScript, which resonates with the group. Steve then demos the console email feature, which sends an email to the val author whenever a function runs, and mentions upcoming features like console SMS and Telegram integration. The segment highlights how Val Town's simplicity makes small stateful programs trivially easy to build and share, even if the underlying persistence model may evolve toward a key-value store.

00:28:09 - Building a Twitter Alert for JavaScript Jam

The hosts decide to build something practical: a Twitter alert that notifies them whenever JavaScript Jam is mentioned. Steve pulls up his existing Hacker News alert val and attempts to adapt the Twitter search query, but the group runs into frustrating quirks with the Twitter API, including queries that mysteriously require OR operators to function and inconsistent results depending on formatting.

Despite the bumps, they eventually get a working search returning JavaScript Jam mentions. Steve demonstrates how he can wrap his Twitter API token in a public function, effectively exposing a scoped, read-only API to anyone on Val Town without sharing the secret itself. The segment is an honest look at the friction of real-world API integration and how Val Town's composability model, with secrets, public functions, and scheduling, handles it.

00:44:00 - API Integrations, Zapier Comparisons, and Use Cases

Steve discusses Val Town's positioning alongside tools like Zapier and Pipedream, noting that while the platform doesn't yet offer OAuth-level integrations, its code-first approach appeals to developers who want full configurability. He shows the community-curated API list, where clicking an integration surfaces examples from other users, and walks through how secrets management works for connecting to services like Slack, Discord, and Telegram.

The group explores the tension between being beginner-friendly and being a power tool, with Anthony observing that Steve's education background naturally produces accessible products that then need to scale toward heavier use cases. Steve shows his "What Can I Make" page with community examples, including a val that auto-posts AI-generated content to Bluesky, and demonstrates scheduled functions that can poll APIs on a cron schedule and fire alerts via email or Discord.

00:49:28 - Express Endpoints, React Rendering, and Sparklines

Steve demonstrates Val Town's Express-style endpoints, showing how a val can return HTML using template literals and server-side rendering. He builds a quick page that displays the JavaScript Jam messages as HTML, then pivots to a more sophisticated example: a self-tracking Sparkline component built with React server DOM that counts its own page views and renders an SVG chart of the data.

The Sparkline example showcases the meta possibilities of Val Town, where a val can track its own usage, store that data in another val, and render a live visualization of the result, all embedded in Markdown. Steve wraps the demo by encouraging listeners to sign up for the free tier, join the Discord community, and explore the documentation and intro video to discover what they can build.

00:54:30 - Future Plans and Closing Thoughts

Steve outlines three key priorities for Val Town's roadmap: replacing the proprietary @ symbol import syntax with standard HTTPS JavaScript imports so code can be copied directly to Deno or Node, making embedded vals work seamlessly in documentation and API docs so users can hit run inline, and turning individual val links into viral-worthy web primitives comparable to GitHub repository links.

He introduces co-founder Tom Macwright, known for his work at Mapbox and Observable and his popular JavaScript opinions blog, along with the small team of four. Anthony and Scott reflect on the platform's broad potential and the challenge of narrowing its pitch without losing its open-ended appeal, and the episode wraps with enthusiasm for where Val Town is headed.

Transcript

00:00:03 - Scott Steinlage

Yo, what's up, everybody? We're back with another JavaScript jam.

00:00:11 - Steve Krouse

Yeah.

00:00:12 - Scott Steinlage

All right. Well, I'm really excited for today. My name is Scott Steinlage. I'm a technical community manager here at Edgio and co-host of this here podcast.

00:00:23 - Anthony Campolo

Anthony.

00:00:23 - Scott Steinlage

What's up? What do you do, man?

00:00:25 - Anthony Campolo

Hello, my name is Anthony Campolo. I'm a developer advocate at Edgio. I'm very excited because we got Steve here with us today. What's up, Steve?

00:00:34 - Steve Krouse

Hey, guys. Excited to be here.

00:00:36 - Scott Steinlage

Awesome, man. Why don't you introduce yourself?

00:00:39 - Anthony Campolo

Yeah, introduce yourself.

00:00:42 - Steve Krouse

I started Val Town about a year ago, and it's a JavaScript platform that runs JavaScript on the server. It's like a social platform that lets you make functions and deploy them and share them and schedule them very easily. That's the dream, at least.

00:01:00 - Anthony Campolo

Okay. Because I remember when you first pitched this to me, you were like, it's like GitHub Gists meets AWS, or something like that. And when you gave that pitch, it sounds more like Netlify and Twitter.

00:01:20 - Steve Krouse

Yes, Twitter is one of the big inspirations. As easy as it is to tweet, it should be that easy to code. You just pop open a text box on a web page, you type in your code, you hit run, and now it lives somewhere. You can publish it, you can share a URL to someone, the code runs, someone else can run it via API, all that. In that way, it's like GitHub Gists meets AWS Lambda.

00:01:47 - Anthony Campolo

Yeah, that's kind of what I think, because I don't really think of GitHub as a social thing. It is in the sense that you can share it to people, it's a link, people can comment on it. But I think of it, at least the way I use it, as more like a centralized repository for my notes and notes that I want to be public or private. So yeah, the pitch still makes sense. It's just like, a thing where code is, and a social thing, those are two of the most generalized possible applications you can build. So it's a very heady pitch to give.

00:02:23 - Steve Krouse

Totally. Yeah. In some ways it's a bit like NPM or a package system, because in the way that it's social right now is that we make it as easy to import someone else's code as tagging them on Twitter. So like [unclear] foo will give you the value of foo that I've defined. And [unclear] foo would be whatever variable name foo that you made. You can't really do that in GitHub or anywhere. I guess NPM does have that kind of ability, but it's not quite as easy to publish something and consume something as we make it.

00:03:06 - Anthony Campolo

Right.

00:03:06 - Steve Krouse

Yeah.

00:03:07 - Anthony Campolo

Okay, cool. We'll definitely want to get into code pretty soon just because I think this is what makes a lot more sense when you actually see it. But let's get some background, find out who you are and how you got here.

00:03:19 - Steve Krouse

Sure. Yeah, I guess my background is in programming education, computer science education, and programming languages and developer tools. So not to go too far into my background, but it all kind of started in middle school for me. I went to this after-school program that taught kids to code, and it really blew my mind. They did such a great job. And then in college I found the work of Brett Victor, which led me to Seymour Papert. And it turns out that teaching kids to code is this long-historied effort to actually make kids mathematical and computational thinkers. And yeah, it was great. It worked in me. I got better at math from learning to code. Ever since then, I've been excited about building programming environments and languages for kids, and just better dev tools for everybody in general.

00:04:11 - Anthony Campolo

I'm really glad you mentioned Brett Victor. This is going to be very good continuity from our last episode. We had Aiden from Millions on and I was telling him who Brett Victor was. I was like, you need to see this dude's videos. They're going to change your life.

00:04:26 - Steve Krouse

Yeah, they certainly changed mine. Yeah, Brett's great. I spent a couple of years. I don't know if you guys saw. I had my own podcast called the Future of Coding for like a couple of years. I was almost like jokingly, I refer to myself as a professional Brett Victor fanboy for like two and a half years. I just like read his papers and his essays and things that he referred to. Kind of climbed up his intellectual lineage tree. It was a great time. It was a great time. Yeah.

00:04:55 - Anthony Campolo

It looks like you eventually got him on the show. You must have been so hyped.

00:04:58 - Steve Krouse

Oh, no, no, no.

00:05:00 - Anthony Campolo

Or is that.

00:05:02 - Steve Krouse

I got some people you.

00:05:05 - Anthony Campolo

Sorry, go ahead.

00:05:07 - Steve Krouse

Well, I'm not sure what you're looking at. I did, I did interview people who worked at Dynamic Land on the show. Two different people.

00:05:14 - Anthony Campolo

Okay. Because I see one says Magic Ink by Brett Victor, but that's just about Brett Victor. That's not an interview with Brett Victor.

00:05:21 - Steve Krouse

Yeah, maybe we're linking. I'm linking to it somewhere or. Oh, oh, I think I know what you're talking about. So I left the future of coding a couple of years ago. Let me look. Yeah, so I left. I left the future of coding a couple years ago. The last interview that I did was 43, and then Ivan did a dozen episodes. And then now Ivan and Jimmy Miller are doing interviews. They're not doing interviews anymore. They're reading old papers that they find really meaningful.

00:05:53 - Anthony Campolo

That makes sense.

00:05:54 - Steve Krouse

And they're talking about them on the show. And so Magic Ink by Brett Victor was one of the episodes. So that is an interesting clickbaity situation. I don't think they mean it to be, but that's how.

00:06:05 - Anthony Campolo

Yeah, yeah, I see. I understand now. And I see there's like, you know, J.C.R. Licklider and Brian Douglas are on here. You know, like, they're dead, obviously, so

00:06:17 - Scott Steinlage

back from the past.

00:06:19 - Steve Krouse

Yeah, they connected up, like, a text-to-speech to ChatGPT-4 to talk to J.C.R. Licklider on a podcast.

00:06:26 - Anthony Campolo

Okay, so for real, that's gonna be a real thing. Okay. Because Tyler Cowan did a mock interview with Jonathan Swift, and it was really great. Like, it was actually interesting. I listened to the entire thing and they had someone, like, read Jonathan Swift's voice and like, for that you can't get, like, data. But if you want to do that for someone who was, like, alive and there's a lot of video for them, like, it's. Oh, it's like, almost feasible with the tech we have today.

00:06:52 - Steve Krouse

Yeah, yeah, yeah. It's the future, I guess.

00:06:55 - Scott Steinlage

Yeah. I mean, there's a guy that created. So have you. I don't know how much YouTube you watch, but there's a guy, his name is CH and he's from New York actually. And he speaks like, I don't know any language you could possibly imagine in the world. And he can learn it very quickly within like a couple weeks. He's, like, having conversations with people. Anyway, super smart guy. And he used to be a programmer, actually, but now he's a YouTuber full time. Like, gets like tens of millions of views per video kind of thing. Anyway. And he actually just. I was actually on. On his email list, and so he just launched a AI language learning software.

00:07:38 - Steve Krouse

What's it called?

00:07:40 - Scott Steinlage

I have to look it up. It's in beta right now. There's only 100 now. There's only 100 people on it. Right. Only in beta. There was Only the first 100 people to sign up got on it.

00:07:49 - Anthony Campolo

Okay.

00:07:50 - Scott Steinlage

But no, this one has him on it. Like as an AI model, he has

00:07:56 - Anthony Campolo

so much content, like a, a trainer.

00:07:58 - Scott Steinlage

So he's, he's the coach. Yeah.

00:08:00 - Steve Krouse

That's cool.

00:08:00 - Scott Steinlage

It's super dope.

00:08:02 - Anthony Campolo

Well, yeah, and that's, and that's easy because you know, if you're putting something within like a lesson format and it's like it's already kind of gamified and then you're basically just playing, putting like clips of voices that go with the gamified thing. So it's like you're making yourself kind of like an npc.

00:08:17 - Scott Steinlage

No, it's like a chat. It's back and forth and it'll like, you'll talk to it and it'll hear you and it'll correct you on how you say certain things and all kinds of stuff.

00:08:24 - Anthony Campolo

It's amazing. Yeah. I'm saying it's all within the bounds of like a set thing which is teaching new language.

00:08:31 - Scott Steinlage

Yeah, yeah.

00:08:31 - Steve Krouse

Right. Absolutely.

00:08:33 - Anthony Campolo

Yeah.

00:08:33 - Scott Steinlage

I think it's still amazing, but.

00:08:34 - Anthony Campolo

Yeah, no, it is. Yeah. No, it's totally. Yeah, it's just, it's just a free flowing conversation with like question answering, you know, but it sounds like it's pretty close.

00:08:44 - Steve Krouse

It's close.

00:08:44 - Scott Steinlage

Yeah.

00:08:45 - Anthony Campolo

Because like, so when you. So can you have like a conversation, like you have a conversation with him in another language and then he just responds to whatever you're saying and he

00:08:53 - Scott Steinlage

can respond in English or Spanish, like if you're doing. Because right now they're only doing Spanish, like that's the main language they're doing. But yeah, and they're going to be adding another language here soon probably. But yeah, there's 100 people in it right now and then they'll open it up to the public here in like

00:09:06 - Steve Krouse

a few months probably. Nice.

00:09:08 - Anthony Campolo

Yeah. Did you have any. Steve, did you have any standout guests back when you were hosting that? Like, you're like, man, I really liked interviewing this person about this topic.

00:09:17 - Steve Krouse

Oh boy, that is. Let me look back. It's funny, I have so many, you know, I'm looking. One of my last interviews with Lane from Coda was like surprisingly good. He's like not a programmer, but he really like nailed the thing that I care most about, like blurring the line between users and programmers or like democratizing the power of programming to more people bringing.

00:09:44 - Anthony Campolo

Right, yeah.

00:09:45 - Steve Krouse

Making programming more user friendly. That was one of my favorites. I don't know, it's been a while. You know, I recorded them in 2018, 2017. So it's been a while since I thought about it.

00:09:57 - Anthony Campolo

Pete Hunt on how React JS was created. That would have been my favorite.

00:10:02 - Steve Krouse

Yeah, yeah, it's, I think that, I don't know if it's the only. Well, I guess now there's the documentary, but there are parts of the React story that Pete said on my podcast. That was like the first place they were publicly said about React. I forget what details, but people were listening to it like, what? How did you scoop these React details?

00:10:23 - Anthony Campolo

And this is one of the things that I love so much about podcasts and good podcasts and how you. If you just find the right person on the right topic, you can find things as like, you have captured like oral history in a way that it's like may. May have never been said or recorded anywhere else. And like, especially if you have people who don't do podcasts very often.

00:10:42 - Steve Krouse

Yeah, yeah. Because it's not a secret. But Pete's not gonna write a blog post about some random story. I don't know if you guys know about how David Nolan's post about React in ClojureScript was a big moment for React. That's where I first heard about React.

00:11:02 - Anthony Campolo

Yeah. I listened to one of David's old podcasts, like 2014, about React once.

00:11:09 - Steve Krouse

Yeah. And so Pete told extra details, I think in my podcast, if I'm remembering right, about how he and David were collaborating before that post. I didn't realize there was all this backstory. Awesome.

00:11:23 - Anthony Campolo

Cool. So what was the kind of inciting-incident moment for Val Town? Like, when did you first get the idea for it, first create the first prototype, that kind of thing?

00:11:35 - Steve Krouse

Yeah, so I've made a lot of prototypes. In my period of time when I was like a Brett Victor fanboy, I was doing a lot of research into making prototypes that would eventually become some sort of project, whether it be an open source project or a company. I guess it became a company. So anyways, I made a lot of prototypes in this space, and I reviewed a lot of tools in this space. I have this thing, the whole code catalog, that was a Future of Coding project where I reviewed things like Glitch and Replit. What else is in this space? Zapier. I've been percolating on these ideas for a while, but really the inciting incident, as you called it, was about a year ago. I had just wrapped up another dev tools project that was a WebAssembly front-end framework. You guys probably might find that interesting. It was Rust to compile to Wasm. It's not maintained anymore. My friend JP started it and recruited me to help him. Yeah, you can still go to zaplib.com, but it doesn't really make sense anymore.

00:12:50 - Steve Krouse

We wrote a post mortem about why it didn't work. We were going to start as a company, we raised some money. It wasn't faster enough than JavaScript enough of the time. If you're listening to this podcast and you like JavaScript and you're a JavaScript developer, the good news is JavaScript is pretty freaking fast and you don't need to make it faster.

00:13:07 - Anthony Campolo

But what about php? I don't think he's PHP for speed.

00:13:12 - Scott Steinlage

That's the thing nowadays, I swear.

00:13:14 - Anthony Campolo

But we were talking with Aiden how he was originally when he was creating Million, he was trying to figure out how to do some sort of like webassembly thing that was going to like improve performance. And he was like actually like you can't really do that if you're comparing it to vanilla JavaScript. Like it's not going to be faster because there's like a level of indirection there.

00:13:36 - Steve Krouse

Yeah, yeah, yeah, JavaScript is pretty freaking fast. And then anywhere JavaScript's not fast that you'd want some native binding to make faster, the web often has it. If you want some sort of encoding thing, web native APIs have good stuff in them. So anyways, that project was winding down, and then I had become friends with this legendary investor, at least to me, Dan Levine at Accel. He was one of the early investors in a lot of companies you may have heard of: Sentry and Vercel and Mux and ReadMe.com, yeah, yeah, Scale AI. And yeah, he and I had become friends over the past couple of months. He found me from my blogging and prototypes podcast, and I was thinking about what to do next. He was really pushing me to work on basically Val Town. He was like, I have an idea for you. Basically he had seen this idea, and he didn't think anyone had nailed it. He thinks that there's a CodePen for the backend.

00:14:53 - Steve Krouse

There's so many metaphors. I've already given a bunch about what Val Town is, you know, Twitter for programming, you know, but he thought there was this hole for a really easy-to-use server-side programming platform where, for him, the vision was that the code and the runtime would be shipped together and they would live at a URL and it'd be this social thing. One of the ways he described it was, isn't it sad that there's dead code on the Internet? Like there's dead code on Stack Overflow, there's dead code in documentation pages, and there is living code in that you can link out to JSFiddle or something, but that's only for client-side code. Wouldn't it be awesome if there was this web primitive where you can embed some code that would run on a server and it would be portable, you could embed it in websites, you could link out to it, you could hand it to someone and be like, this doesn't work, help me debug it. Or this definitely does work, just literally hit run or hit fork, and the code and the runtime, everything, it'll work in your account because it's already there.

00:15:58 - Steve Krouse

Because it comes in this runtime thing. The instigating incident for Val Town was this pitch from a VC. It was a reverse of how these things normally go that I thought was quite compelling.

00:16:12 - Anthony Campolo

Very cool. Yeah, I'd love to get into some code and some demos and get a sense of what this looks like, what it's like to work with. Again, the pitch to me makes a lot of sense. It's like, we got code, we want to share it, we want to collaborate around it. There's lots of tools to do that, but usually it's either a toy demo kind of environment, not really much of a work environment, or it's a really good work environment but it's just for you, not necessarily collaborative. So there are lots of things in this space with different trade-offs. So yeah, I'd love to see what it's like to work with this.

00:16:50 - Steve Krouse

Yeah, totally, great points there. There are definitely a lot of ways in which we're trying to optimize for the personal hobbyist use case for now and grow toward more professional use. Kind of like Vercel did and maybe GitHub did in certain ways. Anyways, enough about that. Why don't I show.

00:17:13 - Anthony Campolo

Last question, actually, how many people are working on this?

00:17:17 - Steve Krouse

It's four of us. Three in New York and one in Seattle. All right, so I hit the present button. Share screen. Should I share my whole screen or just a window?

00:17:31 - Scott Steinlage

Whatever your preference.

00:17:32 - Anthony Campolo

Yeah, it's up to you if you want to. If you're worried about leaking things, you can just share the one thing. If you're going to be hopping around between different programs and stuff and you share the whole thing. Yeah.

00:17:42 - Steve Krouse

Okay. I guess I might as well do the whole screen. Cool. All right. For now, I'll just make it full screen. Is that right? That looks good. Cool. All right. Yeah.

00:17:54 - Anthony Campolo

So this is. And just increase the font a little bit.

00:17:58 - Steve Krouse

Okay.

00:17:59 - Scott Steinlage

One more.

00:17:59 - Steve Krouse

Yep, perfect. Okay, great. Cool. Yes. This is the homepage. If you're logged out, kind of. I don't know, we'll go through these things, but you can schedule functions, email yourself, create APIs, that kind of thing. And you, you know, they're like nascent social network kind of features. You could see what's trending, you could see what's new, that kind of thing. All right. Yeah.

00:18:28 - Anthony Campolo

I find that this is kind of funny because, like, GitHub could have built this themselves, but they didn't because they have gist and they are a social network. Technically, they're just a really bad social network. Like the worst social network.

00:18:40 - Steve Krouse

Totally. I was talking to, I don't know if you'd want me to say who, but anyways, I was talking to someone who used to be high up at GitHub, who said that they had this vision where they were going to make gists into runnable things, and they were laying the groundwork for it, but then the acquisition happened and they moved on to different things. But they still could do it. They still could do it. And that would be an interesting battle for us to fight. I guess for now, I'm glad that they're not doing it. But you do log in with GitHub to get into Val Town. So I logged in. Here are my vals. I have all these folders. So this one is. What's that?

00:19:20 - Anthony Campolo

Let's see, Turso in there.

00:19:23 - Steve Krouse

Yeah, yeah. Oh, nice. Yeah. I was playing with Terse, though. Let's see what's going on here. Oh, yeah. I. I ended up deciding to like. Like I was playing with their database, which is fun, but I need to come up with a project since the project is vaguely related to getting out your Twitter data. And so I made this function that uses someone else's service to turn Twitter IDs into Twitter usernames. Anyways, here I got a list of all my Twitter usernames. Here's everyone I follow on Twitter. Here's all their IDs.

00:20:01 - Anthony Campolo

Oh, my God. This is. This is. Gears are moving. This is a Python notebook for JavaScript. That's what this is.

00:20:09 - Steve Krouse

Yes. Yes.

00:20:10 - Anthony Campolo

Yeah, that's what I thought, too.

00:20:12 - Scott Steinlage

That is literally.

00:20:14 - Anthony Campolo

That is literally exactly what I was

00:20:15 - Scott Steinlage

thinking when he was. You guys were talking, I was like, what's that Python thing called? I can't remember.

00:20:19 - Anthony Campolo

Lab. Yeah, there's a bunch of them. Yeah.

00:20:21 - Scott Steinlage

Notebook.

00:20:22 - Anthony Campolo

Oh, wow. Okay. This is dope. This is super cool.

00:20:27 - Steve Krouse

Yeah. Well, so it's, yeah, it's a lot like a Python notebook, but then it's like, I can send you this URL and it's like a web primitive at a URL, like with the data. So here, let me pop open an incognito tab. You could still see this even though I'm not logged in. And you can go into this menu, copy the name, and compute with it. So this is what I was saying: you can use someone's values as easily as you tag them on Twitter. So [unclear] following dot and then, well, it should let me dot IDs. There's a bug in the type completion, but that should work. Let's see. Is it not IDs? Oh, I'm not parsing it as JSON because I'm nervous that these numbers are too big to be parsed as JSON numbers, but I think I am being silly for worrying about that.

00:21:29 - Anthony Campolo

Awesome. Let's build one of these from scratch.

00:21:33 - Steve Krouse

Okay. Anyways, yeah, let's build something from scratch. I think that'd be more fun. Okay, so the thing I was thinking we would do is, one of the things we're good at in Val Town is we make it relatively easy to store small pieces of state. So here, I made an empty folder for us. So I'll do jsjam messages.

00:21:55 - Anthony Campolo

You probably bump up the font. Just one more.

00:21:58 - Steve Krouse

All right, let jsjamMessages... I'm sorry. Okay, so let jsjamMessages = [] in Val Town. And I'll make it public. So now you guys can see it if you wanted to. There's nothing going on there yet. This is a public thing. You guys could read from this value if you wanted, but only I can write to it. And I can write to it just like I would write to a JavaScript value, so I could do function newJsJamMessage. That @me is a short handle for my username.

00:22:45 - Anthony Campolo

Yeah. I was going to ask what the things are. So the at. Is that a VAL primitive?

00:22:50 - Steve Krouse

Yeah. So this is a Val Town thing and it's nice, but it's not a web-standard thing, obviously. So we probably will move away from this and have like a Val Town version 2, which doesn't use the at symbol.

00:23:04 - Anthony Campolo

Because I was looking when you were scrolling through your other stuff, I saw some of those and I'm like, wait, is that decorator, or is this like a DSL?

00:23:11 - Steve Krouse

Yeah. So it links everything together. So I can command-click this and it'll take me to this, which is also right here. Yeah, we compile it down. It's one of the decisions about Val Town that I think was a fine decision for the time, but I don't know if I regret it. We are probably moving away from it to something that makes sense because

00:23:32 - Anthony Campolo

you want people to be able to just hop in and write code like it's JavaScript enough to worry about other stuff or learning other things.

00:23:40 - Steve Krouse

And the other way around, we want them to be able to copy and paste their Val Town code to Deno or Node and just hit run and it just runs. We don't want to lock you into using our proprietary syntax.

00:23:50 - Scott Steinlage

What if it just extracted that out? Potentially. Yeah.

00:23:59 - Steve Krouse

The tricky thing will be how we keep all the functionality we currently have without this. It's a long project, probably will take us a number of months, and we'll do it in pieces, and I can talk more about that maybe toward the end once you guys see all the different things that it can do. Now that I've made this function, I've made it public. You guys, even without a Val Town account, can go ahead and call this function and it will add to my messages. The code you would run, I'll just do it for starters, but if you guys want, you can do it. It's like, hi from Steve. Cool. It ran and then it created a new version. Version 0 was the first version, and version 1 is this one that was set by this function at this time. And here's the new message. Does that follow? Cool. It's like small pieces of state in persistent JavaScript values on your namespace. That's one of our marquee features. Then I could also do that.

00:25:16 - Anthony Campolo

It doesn't go anywhere. It's just free floating for when you're running it.

00:25:21 - Steve Krouse

The state is saved right here in JSJM messages. Okay.

00:25:27 - Anthony Campolo

Every time you have a database running in the background, that's just like saving everything.

00:25:35 - Steve Krouse

Currently a VAL is a val. This is a VAL that's just a function and this is a VAL that just returns undefined. It's some code, it returns undefined. This is also a valid. The only difference was that this VAL was set from another val.

00:25:56 - Anthony Campolo

I'm just curious what are you running on the backend to have all this persist?

00:26:01 - Steve Krouse

Vals are stored in a postgres database. There is a row in a postgres database that points to JSJAM messages and then there's another postgres table that has all the versions of JSJ messages. Yeah, this is very easy and relatively quick for folks to pick up. It's also not so web standard. We're probably going to move to some sort of key value store instead of this. This works pretty well for now, but we can keep going. One of the best features we have is console email. You can send yourself an email where you send them new message. This is the subject line, this is the message. You don't need it. The subject line is optional. Now whenever this runs, I'll just get an email in my inbox. I don't really want to send an email. I don't want to pull my email up because who knows what's in my inbox. But you guys can trust me that I got an email with the subject line, new message and the value of the message as the contents. Cool. Yeah, people really love that feature and it comes in handy a lot. We're in the middle of building some new ones.

00:27:26 - Steve Krouse

Console SMS is taking a while to build because it's hard to get registered, but we're working on that one. I was all like basically the whole day today before this call. I've been working with one of these, this, this user on making a like a telegram, a way to message yourself on Telegram which is so easy. Yeah, the Telegram API is really easy to use and so he and I were working on this docs for how to set it up. So. So anyways, back to this demo I guess. I don't know if you guys want to try like calling this val.

00:28:09 - Anthony Campolo

Yeah, just like drop the, drop it in the chat and we'll take a look at it.

00:28:13 - Steve Krouse

Cool. And yeah, just like edit it and

00:28:17 - Anthony Campolo

so do you have like API integrations or is there also like zapier like kind of functionality? So it Seems like this also would be really good for that kind of stuff.

00:28:28 - Steve Krouse

Yeah, we're really. The short answer is we want to be good at those things. We are decent at those things. But at the current moment, we're struggling to figure out is it like zapier where you oauth in, or is it a little bit lower level where you copy and paste keys?

00:28:50 - Scott Steinlage

Kind of interesting, actually. When I saw this layout, like how you guys have this set up, it very much reminded me of Pipe Dream, actually.

00:28:58 - Steve Krouse

Yes. Yeah.

00:28:59 - Scott Steinlage

Which is. Which is totally.

00:29:03 - Anthony Campolo

Totally.

00:29:03 - Steve Krouse

Yeah, yeah, yeah.

00:29:05 - Anthony Campolo

That's why I actually interviewed a Pipe Dream once. I'd never even heard of them. I love that product.

00:29:10 - Scott Steinlage

I think it's cool.

00:29:12 - Steve Krouse

Yeah, I agree.

00:29:14 - Scott Steinlage

And now they have an AI in there to write out.

00:29:16 - Steve Krouse

Yeah. Code.

00:29:17 - Scott Steinlage

It's so cool.

00:29:17 - Steve Krouse

Yeah, yeah, to make your Pipe Dream integrations. Yeah, Val Town is like, we are trying to compete in the Zapier/Pipe Dream market as well. That's one of the best uses for Val Town today, connecting two APIs. And I can show you some of my examples of that here. Yeah, maybe now's a good time for that. But I was going to show you how we're doing APIs today: we have this kind of cheeky list of all these APIs that someone has used. And then when you click on it, we just do a search for who's mentioned it, and then you can look at examples of people using the Slack API and you just have to adapt it to yourself. We don't have anything at the platform level that helps you. We're just showing you that other people in Val Town have done Slack things. This one we put together that we show you: if you save a Slack webhook URL in your secrets, and I'll show you where our secrets are, they're just in here, Secrets, then this would work if you forked it. Anyways, it's not quite an OAuth experience.

00:30:34 - Steve Krouse

We'll probably move there eventually, but we're not there yet. Oh, I was going to show you some of my poll jobs that I have running, which are good examples of what people use Val Town for.

00:30:51 - Anthony Campolo

That was actually one of my questions, what kind of stuff people are building.

00:30:55 - Steve Krouse

Yeah. So this one, I feel like these ones are classic. Whenever Val Town is mentioned on Hacker News, I'll send myself an email, like a console email, that we were mentioned on Hacker News. I'll also send it to our Discord. This is a good example of Discord not being built into the Val Town platform, but in user space I built a way to message yourself on Discord. All that we need is your Discord webhook URL. I need to add a README to this val to explain how to get your Discord webhook URL. Just a couple clicks, but I do need to put that in there. I don't know, it's fun to compare this to Zapier or to Pipe Dream, because in some ways this is a lot harder to understand what's happening here. But in other ways, if you're a programmer, it's cool that it's all code and it's fully configurable.

00:31:53 - Scott Steinlage

Yeah.

00:31:54 - Anthony Campolo

It seems like you're in this interesting mid-ground right now where this is useful, I think just because of your background. I find people with this kind of background have a hard time avoiding it, that you build things that are useful for learning and that generally help people understand how stuff works and are very easy to use. And then it's a question of like, all right, cool, so then what are things it can kind of do? What are things it can accomplish for you? And then it's like you can't take something that is very simple and easy to use and beginner-friendly and then try to figure out how to turn that into a power tool that can do really heavy workflows for you. So there's kind of a tension there between those two goals.

00:32:33 - Steve Krouse

Totally, totally. Yeah. Yeah. It's definitely one of the things that we've had a hard time answering. We recently made this page. I'll zoom out a little bit, like, "What can I make in Val Town?" to kind of help walk you through things people

00:32:53 - Anthony Campolo

have made annoy friends in Blue Sky.

00:32:56 - Steve Krouse

Where is that one? Yeah, yeah. Like this one someone just made and it's hilarious. It. It uses da Vinci. Yeah, it's interesting.

00:33:08 - Anthony Campolo

Dude, this is exactly like when I was using Blue Sky, I was just like churning out chat GPT. You were content. Just because I was like, I'm gonna write more stuff for a new.

00:33:17 - Scott Steinlage

Write a short story about aliens.

00:33:19 - Steve Krouse

All right.

00:33:19 - Anthony Campolo

Exactly.

00:33:20 - Steve Krouse

Yeah, yeah. I was going to show you, I don't know if I feel like this val might not be working at the moment, but it dovetails with our earlier conversation. This is Brett Victor's handle on GitHub, worrydream. I think there's something weird with the GitHub API. I haven't been getting events, maybe just because he hasn't been on GitHub recently, but I was using it to see whenever Brett Victor contributes to GitHub, I get an alert. Alerts are something that Val Town is really good at because you just hit this schedule button here. I'll hit stop. You hit schedule here, Schedule. Then it defaults to running every hour. You can have it run every day. You can have it run on a cron schedule. Then it will pass in some parameters of the interval, including the last time the interval ran in as the first argument to the function you have here. Then you could just say, has there been any new events since I last saw events? And if so, then email them to me.

00:34:29 - Anthony Campolo

Could we try and build out the hacker news follow one but for JavaScript jams Twitter. So every time we're mentioning on Twitter it triggers it. Because that would be useful for us.

00:34:39 - Steve Krouse

Sure.

00:34:40 - Anthony Campolo

That's something we can actually use.

00:34:42 - Steve Krouse

Yeah, yeah, totally. It's one of my favorite. This. This is it right here. Unless you wanted to build it from scratch, which.

00:34:51 - Anthony Campolo

No, no, I'm saying if you already have the code, it's even better.

00:34:54 - Scott Steinlage

Just plug us in there.

00:34:55 - Anthony Campolo

Yeah, just show. If you could just do it that way then like that's even more impressive. So. And I, I just want this like literally. So let's do it. Give it to me now.

00:35:06 - Steve Krouse

Yeah, okay.

00:35:07 - Anthony Campolo

It doesn't happen very often, but every now and then bro Nifty will be like, hey, this is how actually, so this is funny. This is how this happened right here is that you were asking for guests and bro Nifty tagged us and said, hey, you should go on JavaScript jam. And also it's nice to have a place where actually that's going to go. We're not going to have Slack anymore, so don't go to Slack. But one day it'll go somewhere where Ishan can see it too.

00:35:30 - Scott Steinlage

True.

00:35:31 - Steve Krouse

Nice.

00:35:32 - Scott Steinlage

Here you can just email community growth.

00:35:36 - Anthony Campolo

Yeah, there we go.

00:35:37 - Steve Krouse

JS Jam. Okay, so what's a good. Yeah, what's the query that we want?

00:35:45 - Anthony Campolo

So basically just like if it's mentioned in the Twitter at all. So just like if we're added JavaScript jam.

00:35:55 - Steve Krouse

So it's specifically the Twitter account itself.

00:35:59 - Anthony Campolo

Yeah, the JavaScript Jam Twitter account. If I were to write a tweet right now saying, hey, JavaScript jam, what's up? That would then trigger.

00:36:09 - Steve Krouse

Yeah, there we go. Okay, cool. Well, that's Very easy. Yeah, I think handles, I think are very easy. Let's hit run and see what example. Nothing in the last six days. Maybe I can just remove the start time and see. It could be a broken.

00:36:29 - Anthony Campolo

Let me do one right now.

00:36:30 - Scott Steinlage

I did something a couple.

00:36:31 - Steve Krouse

Yeah. No, no, yeah. No, I think. I think the query is just broken. Let me see. Twitter search might not work with the

00:36:40 - Anthony Campolo

Twitter API has been constantly breaking forever.

00:36:44 - Steve Krouse

That's true too.

00:36:46 - Anthony Campolo

Yeah. Are you paying for the Twitter API right now?

00:36:48 - Steve Krouse

I am, yeah. It's $100 a month. That's the most complicated part about. So you get V2. Yeah. Let me see if it's working at all.

00:37:02 - Scott Steinlage

Or you get V1 stuff because, like.

00:37:07 - Steve Krouse

No, yeah, I'm not getting anything. Let's see. I have two keys because things are being weird. Yeah. Right now it's possible that just like the whole Twitter API is broken.

00:37:22 - Anthony Campolo

Yeah. Could we try our. Could we try our podcast RSS feed? Like link something up to that? I'm trying to think of something we could do with JavaScript jam stuff.

00:37:33 - Steve Krouse

Oh, yeah, of course. Do you want to get a notification whenever there's a new entry in your RSS feed? Is that like, kind of what you're. I have things like that or you want to go. You can generate an RSS feed. We can consume an RSS feed.

00:37:50 - Anthony Campolo

Yeah, yeah, totally.

00:37:51 - Steve Krouse

Yeah.

00:37:52 - Anthony Campolo

Try to think of just like, you know, events that could. Or like. Okay, how about this? Twitter, like something that happens when a new episode is published. Like, it automatically creates some sort of. What, like, so what other social networks are you hooked into, aside from Twitter?

00:38:11 - Scott Steinlage

It opens up chat GPT and it creates a summary for us and it does everything well.

00:38:16 - Anthony Campolo

When the episode is published, there should already be a summary.

00:38:18 - Steve Krouse

That's.

00:38:19 - Scott Steinlage

Oh, right. Yeah, that's true.

00:38:20 - Anthony Campolo

Yeah, that's true. So try to think of like, what's the. Once it's published, like, logically would be then shared on Twitter. But like, we're trying to get around the Twitter thing right now. So, like, what other things do we share it on? Nowhere really.

00:38:32 - Steve Krouse

Yeah.

00:38:33 - Scott Steinlage

I mean, hold on.

00:38:35 - Steve Krouse

It just worked. I don't know. Oh. Oh, you know what? I bet. Yes. I think. I think that's what it is. If you don't put it in quotes, then it assumes it's a handle. So.

00:38:47 - Scott Steinlage

Oh, right.

00:38:48 - Steve Krouse

Got it. Yeah. Yeah. Okay. So where was your. There. So I think. I think this might. Let's try that.

00:38:58 - Scott Steinlage

What is a handle, though?

00:38:59 - Steve Krouse

But no. Okay, that didn't work. Let me put it in quotes. All right. Let's see. Yeah, I guess at some point we could go into the. I can pull up in the Twitter. Twitter API search docs.

00:39:29 - Scott Steinlage

Yeah. Oh, gosh, this is all too familiar.

00:39:33 - Anthony Campolo

Never really gotten into the Twitter API before.

00:39:35 - Scott Steinlage

Oh, it's a headache.

00:39:38 - Steve Krouse

Yeah.

00:39:40 - Scott Steinlage

I was trying to create a. An app that would track people sharing live, you know, life using their Live feed feature on here on the API instead of a REST API. And I was trying to make it listen to a certain post and see how many people like retweeted it and liked it for like a giveaway. And then take those usernames and put them in a. And automatically run through and pick a random winner.

00:40:23 - Steve Krouse

Yeah, which.

00:40:24 - Scott Steinlage

There's already things out there like that.

00:40:25 - Steve Krouse

But. Okay, I think. Here, let me try. Where was I? Here. JavaScript jam. Here, I'll try that. No, I can try a JavaScript DRAM URL maybe. No, that's not working. What is going on? This works.

00:41:04 - Anthony Campolo

So, so what is different Going through the. The bearer token. You're not. Because like. So what is the query doing in the one that's working right now?

00:41:14 - Steve Krouse

All right, here. I will. I copy and paste it from the one that's working. Great. Still working. Okay, we have.

00:41:23 - Anthony Campolo

Can you guess. Let's stop right now and let me ask some questions. So what is happening in the query that's working? You have Valtown written three times. The bunch of random crap. I have no idea what's happening in

00:41:35 - Steve Krouse

this query right now. Yeah, I'll get it back to working. Yeah, I could start with the first line.

00:41:43 - Anthony Campolo

Okay, so say either this or that and then what's the difference between.

00:41:50 - Steve Krouse

This is a. Not query because there's someone else out there. There's a. There's this like rapper named Val Town.

00:41:58 - Scott Steinlage

Right?

00:41:59 - Anthony Campolo

And.

00:42:01 - Steve Krouse

And like we get crazy stuff when people talk about him and we don't. We explicitly don't want.

00:42:06 - Anthony Campolo

So why don't we just try modifying this to be JavaScript jam?

00:42:12 - Steve Krouse

Kind of what I've been doing. Yeah, but. But I can. I can throw in an or. Well, and then do jam. That should still return.

00:42:27 - Anthony Campolo

Shouldn't you change?

00:42:28 - Steve Krouse

Oh, cool. What's up? JavaScript jam.

00:42:30 - Anthony Campolo

Yeah, yeah, that's what I just got something.

00:42:32 - Steve Krouse

Okay, amazing. So now I'm going to delete some things and see if it still works.

00:42:36 - Scott Steinlage

See where it breaks.

00:42:40 - Steve Krouse

It's crazy that it's taking so, so much. So much.

00:42:43 - Scott Steinlage

Okay, it still worked. Hey, there's me.

00:42:48 - Steve Krouse

Stopped working.

00:42:50 - Scott Steinlage

What the frick.

00:42:52 - Anthony Campolo

So what is the Val Cow doing again?

00:42:54 - Scott Steinlage

Yeah, there's A dot.

00:42:57 - Steve Krouse

Yeah. What is this?

00:42:59 - Anthony Campolo

JavaScript jam, right?

00:43:01 - Scott Steinlage

I don't know.

00:43:02 - Anthony Campolo

I can't guess.

00:43:03 - Scott Steinlage

I don't know. Yeah, I don't even know.

00:43:08 - Steve Krouse

What is that? It's so weird. Let me remove this and keep that

00:43:13 - Scott Steinlage

still, see if it does it.

00:43:15 - Steve Krouse

Yeah, no, so it doesn't work really? Oh no. Hold on, hold on, hold on. Let me remove that. Ah, yes, right.

00:43:23 - Scott Steinlage

There we go.

00:43:24 - Steve Krouse

This is. This is so confusing. Why, why it needs here. Well, actually, why don't I do JavaScript Jam or JavaScript Jam?

00:43:33 - Anthony Campolo

Yeah, let's see.

00:43:34 - Scott Steinlage

Sure.

00:43:34 - Steve Krouse

Because you guys might want two things anyways.

00:43:37 - Scott Steinlage

Who knows?

00:43:38 - Steve Krouse

Okay, that's working.

00:43:42 - Scott Steinlage

So you have to have the OR or, I guess.

00:43:44 - Anthony Campolo

Okay, yeah, that's. There we go.

00:43:46 - Steve Krouse

Yeah. Why do you need an OR query? Yeah, I don't know, it might be like the way that I'm implementing it. Or it could be a bug.

00:43:57 - Anthony Campolo

Weird bug going on.

00:43:58 - Scott Steinlage

Yeah, yeah.

00:44:00 - Steve Krouse

Maybe queries require ORs. Yeah, maybe you can't just do something by itself in the Twitter API. Maybe like that's a different. That's something else. I don't know. Whatever.

00:44:13 - Anthony Campolo

This is working now that we. Then. So now we're getting the output. Then is there any sort of way to then take Val Town's output and then pipe that somewhere else?

00:44:24 - Steve Krouse

Yeah, yeah. So ultimately you want a fork of this val that I call TwitterAlert. So you want basically this. But this is the query part that we'll just replace with a query for JavaScript Jam, and then if there are no results, we just end the function. Otherwise, I guess here you can ignore this part for now. This is, I think, just formatting text.

00:44:49 - Anthony Campolo

Formatting URLs gonna email it at the end.

00:44:53 - Steve Krouse

This emails it to you. This sends it to, like, a Discord place if you want.

00:44:57 - Anthony Campolo

So okay, so let's just do the email then. We don't have a Discord set up, but email will be useful. We have a shared one with me, Scott, and Eshan that we could send it to.

00:45:07 - Steve Krouse

Okay. Yeah. So console email only emails the author. So you guys would just have to fork this. So the two things about this that are hard are, one, you'd have to... well, forking is easy. You create a Val Town account, step one. Step two, you hit fork and save.

00:45:24 - Scott Steinlage

So we would need to sign up with that community email we're talking about. Yes, the email from your account.

00:45:30 - Anthony Campolo

Exactly. Yeah. So I already have a Val Town account. So I could just switch it to that, because you can add multiple email addresses, can't you?

00:45:41 - Scott Steinlage

Does it only email the main one, though?

00:45:44 - Steve Krouse

Yeah, it'll only email the one. Let's see. I don't know, where is it Preferences? Let's see. Yeah, you can add an email address and then maybe make it prime and then possibly you can make it primary. I don't know. This part of the product we're using Clerk for authentication, which has been a little bit troublesome. Shout out to Clerk. Yeah, it's. In some ways it's been great. In other ways it's been like, at

00:46:12 - Scott Steinlage

least you didn't have to roll your own brother.

00:46:14 - Steve Krouse

That's true.

00:46:16 - Anthony Campolo

So you can have two email addresses. One will be primary and one won't be.

00:46:21 - Steve Krouse

Yeah, I don't know. I think the easiest way to do it is to sign up for Val Town with that second email address and then see what happens, and then use console email. But the tricky thing here is that you'd have to either sign up for the Twitter API, or use your token, or use my token. And so that would work, though, because you have...

00:46:47 - Scott Steinlage

So do you plug your token into the back end of this or where's it at?

00:46:51 - Steve Krouse

Like, where's your great question. Yeah, so I have my token here in Secrets.

00:46:56 - Scott Steinlage

Okay. So that's where it is. Oh, right, you showed us that earlier.

00:46:59 - Steve Krouse

Okay, so what I can do just for the purposes of this demo is I can copy and paste this to a new function and call it TwitterJsJamSearch. And I'll just take in startTime as a parameter. But everything else I will use on my own. This can be the default.

00:47:35 - Scott Steinlage

What are the limitations if you're not paying for the Twitter API? I can't remember nothing.

00:47:39 - Steve Krouse

You can't, I don't think you can get almost anything. I forget. Anyways, okay, so I made this a public function. And I have my secret in it, so you can call it. And we didn't even talk about this really, but every function in Val Town that's public, private ones too, private ones work via passing your Val Town API token. But anyways, we'll just do public functions because that's easier, and that's the whole point of this. So we have two kinds of API functions: a run endpoint, which works with any JavaScript value, and then an Express endpoint. If you want a custom HTTP endpoint, you can make a request handler, take in a request object and response object, and do the Express things. But anyways, right now we're doing the run API. I can just run this. Whoa, what happened? Why? Okay, no, sorry, I just added a space or something. This just ran this function and returned the results of JavaScript searches for you guys. You can call this API from Val Town for yourself and check it every so often by passing in the start time.

00:49:04 - Steve Krouse

Then if there are results, you can console.email yourself or send it to Discord or Telegram or wherever else you want to send it. Hopefully Val Town has that function, or someone else has already made that function to send it where you want to go. What I've done is I've exposed an API that pokes a hole and gives you some small access to my Twitter token.

00:49:25 - Scott Steinlage

Yeah, that's interesting.

00:49:27 - Anthony Campolo

Wow.

00:49:27 - Steve Krouse

Sweet.

00:49:28 - Anthony Campolo

Cool. Are there other things you want to show before we start wrapping it up?

00:49:34 - Steve Krouse

I guess maybe just a quick thing I'll show is that Express endpoint and how you can use it to return HTML. Let's see, I'll go back to my... Val Town isn't really the place that you want to be doing HTML, kind of. Sometimes it's just really convenient if I want to.

00:49:53 - Anthony Campolo

You can have an endpoint that exposes some HTML and then that gets fed into a web page or something.

00:49:59 - Steve Krouse

Exactly, yeah. You have to use an Express endpoint for HTML and you just do res.send and then you can do HTML. And we do have some helpers to make this easier to do certain React-y things in HTML. And then if I wanted to render these in there, I was going to map over it and do it as a list, but I don't want to waste the time, so I'll just throw it in there. I'll just JSON.stringify it. All right. I'll just put the whole thing in h1 so you can see it is HTML. Save. That's the wrong thing. Where am I? Cool. Those are the messages in HTML and you can map over them and make them li elements. It's server-side rendering. It looks like React in some ways, but it's really just using JavaScript template literals. We're injecting this value on the server. You can make a whole form do

00:51:35 - Anthony Campolo

the other built-in integration with stuff like React. So you could just write React in a val? Yeah, an individual val.

00:51:43 - Steve Krouse

Are they called anything exactly, like tweets? Yeah, they're called vals. Let's see. I did some React yesterday and I'm so into it. Okay, so this is Sparkline. This is a Sparkline that I made using HTML to generate React components, React server DOM to stringify them. And then this Sparkline library that I found on npm. And then here I'm actually keeping track of how many times people are loading my Sparkline library, how many people are loading this val itself. Then here I'm actually generating the SVG and sending it here. This val itself is an Express endpoint. So this is that val. And this val itself is keeping track of how many times you run it. So every time you run it, this value over here is going to get higher because it's counting how many times it's been run. It's very meta.

00:52:41 - Scott Steinlage

There you go.

00:52:43 - Anthony Campolo

Yeah.

00:52:44 - Steve Krouse

And then I'm embedding it here in Markdown. So this is an embedding of its own thing. So you'll see that it's higher here than it was here because we've reloaded the page. So it's. It's. It's so meta. I love it. So anyways, this is an example of a reacty thing that we're doing. I also have a vanilla spark. This is the. No, that's the data of it. Yeah, this is the data. This is like where we're keeping track of how many times this page has been loaded. Like how many times today has been loaded. Either 0 or add 1 to what it was before. But I also had like a vanilla JavaScript version of the Sparkline. Yeah, here's the vanilla JavaScript version.

00:53:29 - Scott Steinlage

Mr. Ferdinandy would like this.

00:53:31 - Steve Krouse

I have a sparkline. Yeah, you just need like this. Sparklines are so easy to generate in just pure JavaScript and yeah, that's the example of it. So anyways, that's enough. If anyone is still interested. Just signing up, it's free. Watching the, the intro video, reading the docs. We do have a paid plan for like extra compute and stuff. And then. And then you really. I would recommend joining the. The Discord. We're quite friendly and active on there. So that. Is that cool.

00:54:08 - Scott Steinlage

That's awesome.

00:54:08 - Anthony Campolo

Awesome, man. Yeah. So yeah, this is super cool. I'm very into it. It's a lot of possibilities of kind of what you could do with it. So I'd imagine part of the challenge is just figuring out like how to make the pitch, how to make the docs easy to use, how to like communicate what you can do with it and then how you can do it with it.

00:54:30 - Steve Krouse

Totally. Yeah. You've hit the nail on the head. It's like almost too open ended and trying to eat too much. So yeah, the challenge is narrowing down while like we want to conserve the broad applicability but also be good at things, not just be like kind of okay at everything.

00:54:51 - Anthony Campolo

Right? Yeah. So what's like kind of the future, like short term, long term, what are you like working on right now? What's like the long term vision? Any of that kind of stuff?

00:55:00 - Steve Krouse

Yeah. Okay, I got three things for you. So we really want to push on JS web standards. The plan right now is to remove the @ symbol as a way to import code and instead have standard HTTPS JavaScript imports at the top. You'll type the @ symbol in your code like you currently do in Val Town, or like you would in Notion or anywhere like that, and you hit enter and we'll throw up an import at the top and then just the name of the variable down below. Basically any link to a val, if you just add .js at the end, it'll be like a raw link to that JavaScript, like raw GitHub user content. Then you'll be able to copy and paste from Val Town to Deno and it'll just run, or Node. That's one thing. We want to move entirely to web standards. That's a big challenge. Another thing we're working on is embedded vals working really well. Like it would be awesome if, when people are explaining an npm library, vals are embedded throughout and you can just hit run and edit the code, hit run, and that just works.

00:56:11 - Anthony Campolo

Embedded in Markdown or Read me or something like that.

00:56:14 - Steve Krouse

Exactly. Or API docs. Like if you're an API company and you're trying to show people how to use your API, it's even better than an SDK to have running code. Just hit run and grab this into wherever else your code is going. Then the last thing overall, a thing that we really want to see happen, is val links. Links to individual vals being on the front page of Reddit or Hacker News, or going viral on Twitter in the way that a GitHub repo does. It's magical how GitHub repos are this web primitive that you can post anywhere and the README is pretty. And people like GitHub repos, and we would like vals and val links to have that same kind of social behavior. And we're working on it, but it's been challenging so far.

00:57:06 - Anthony Campolo

Word? Yeah. No, that's awesome. It's so many opportunities, so many things you can do with it and it's pretty freaking sweet. And you kind of like, you're kind of like the sole founder. Do you have a co founder who's also working with you on the vision thing or it's just like you and a bunch of engineers?

00:57:22 - Steve Krouse

Oh, it's me. And my co-founder is Tom MacWright. He joined a couple months into the company. He worked at Mapbox and Observable. Observable is also like a JavaScript/Python notebook kind of thing, but it's all front-end based. Tom's really great. He has a big JavaScript personality. People like his opinions on frameworks and JavaScript-y things. I was a reader of his blog. That's how I first found out about Tom.

00:57:54 - Anthony Campolo

And

00:57:56 - Steve Krouse

then there's one designer, Rodrigo, and one engineer in Seattle, Andre.

00:58:01 - Scott Steinlage

So everybody thought Cliff Notes was dead, but Cliff had a sister and her name was Val. I don't know, maybe it's a little too much.

00:58:15 - Anthony Campolo

This Cliff Notes was Cliff Notes.

00:58:17 - Scott Steinlage

You're like, come on, that's like 1990s

00:58:20 - Anthony Campolo

when we're actually reading short books.

00:58:23 - Scott Steinlage

Yeah, yeah, yeah. It's like, it's like a note thing, you know?

00:58:26 - Steve Krouse

Yeah. Anyway,

00:58:29 - Scott Steinlage

anyway,

00:58:33 - Steve Krouse

cool. Well, thanks Close out for us, Scott.

00:58:37 - Scott Steinlage

Yeah, awesome. Thank you so much, Steve. Greatly appreciate you, man. It's been really cool to see what you guys have been working on and the things in the future. I'm excited to see what all happens with this and how it evolves over time. I'm sure you guys are gonna do some amazing, really cool things as you already have. So thank you very much. Thanks Anthony, for joining me here as well. Yeah, that's it. So thank you all for joining us on JavaScript Jam and we'll see you in the next one.

00:59:08 - Anthony Campolo

Next one.

00:59:09 - Steve Krouse

Peace.

On this pageJump to section