Simple Charting with BoxLang / / No Comments Building a BoxLang and want to know how to do charting with it? The answer is simple… don’t! I kid! Sorry, but for many, far too many, years now I’ve argued that ColdFusion should not include a charting library. It’s a server-side language, and in my (definitely not) humble opinion, client-side code doesn’t belong there. (I’m fine not worrying about that though – I trust that team knows their clients better than I do and knows what they’re doing.) The good news (again, imo) is that BoxLang doesn’t ship with an embedded client-side charting library. That being, I can absolutely see cases where you may be building a web app in BoxLang and want... more → Posted in: JavaScript Tagged with: BoxLang, Charting, simple
Simple Blog Example in Flask / / No Comments As part of my efforts to improve my Python knowledge, I’ve been looking at the Flask framework for a way to build Python-backed web apps. I’ve only been looking at it for a short time, but I’m really impressed with how simple it is. In some ways, it reminds me a lot of when I first saw Express. Before that, I wasn’t sure I was going to like Node.js as it felt like a lot of work to build a simple app, but Express handled a lot of the boring parts. The same applies to Flask. To get an idea of how easy it is, here’s the basic "hello world" from the quickstart: from flask import Flaskapp = Flask(__name__)@app.route("/")def hello_world(): return... more → Posted in: JavaScript Tagged with: blog, example, Flask, simple
Adding Simple Routing to Cloudflare Workers / / No Comments I’ve been "playing" with serverless for years now, but honestly still feel new to it. When it comes to organization in a project that uses serverless functions, I’ve typically tried to build one function per operation. So for example, if I had a need to get a list of cats, I’d have one function. If I had a need to get information about a cat based on an identifier, I’d probably build a second one. That being said, I recently came across an example Cloudflare function that did something cool – it used a router, specifically the very lightweight itty-router. Let me share an example of how it works. What is a Router? # So I kinda assume most folks know what... more → Posted in: JavaScript Tagged with: Adding, Cloudflare, Routing, simple, workers
A Simple Slideshow Web Component / / No Comments As I continue to play around with and learn more about web components, I thought I’d build a simple component to make it easier to add a slideshow. By that, I mean something that renders one picture but provides controls to go to more images. I’ve probably built this many times in the past, both in JavaScript and server-side code, and I thought it would be a nice candidate for a component. As with most of my demos so far, there’s a lot more that could be done with it, but I thought I’d share what I have so far. Once again I want to give a shout-out to Simon MacDonald for helping me get this code working. (At the end of the post, I’ll share the mistake I made, as... more → Posted in: JavaScript Tagged with: Component, simple, Slideshow
The ins and outs of JavaScript reducer — a simple, yet powerful array method – The Next Web / / No Comments The ins and outs of JavaScript reducer — a simple, yet powerful array method The Next Web “JavaScript” – Google News… more → Posted in: JavaScript Tagged with: Array, JavaScript, method, Next, outs, powerful, reducer, simple