NIMBY Mapping / / No Comments In July the German government introduced a draft bill to legalize cannabis for personal use. However, under the draft bill, the consumption of cannabis will remain prohibited within a 200-meter radius of schools, children’s and youth facilities, playgrounds, publicly accessible sports facilities, and in pedestrian zones between 7 am and 8 pm. According to the Berliner Morgenpost these Maps Mania… more → Posted in: Interactive Maps Tagged with: Mapping, NIMBY
Working with the Storage API / / No Comments Earlier this year at WWDC, Apple announced a whole set of new features coming to Safari in version 17. While that is not out yet, it’s still a pretty large set of updates. I’ve not been shy about my view that Safari has been holding the web back for a while, but I’m happy for any improvements that show up. While looking at the long list of updates, I saw Storage mentioned: WebKit has made some big updates to the storage quota policy. Previously, an origin had a starting storage limit of 1 GB. When exceeding the limit, the subsequent storage operation would fail in Home Screen web apps, or the user would see a prompt asking to increase the quota for the origin in Safari. Starting... more → Posted in: JavaScript Tagged with: storage, working
A New Google Map of the Brain / / No Comments If you’ve ever wanted to look inside someone’s brain then you might like the European Commission’s new ‘Google Map’ of the human brain. This new 3D map allows you to take a look inside a human skull and explore atlases of the brain’s regions and neural connections.The European Brain Research Infrastructure (EBRAINS) is funded by the European Commission to accelerate brain research and Maps Mania… more → Posted in: Interactive Maps Tagged with: Brain, Google
queryLocalFonts / / No Comments One of the larger downloads when requesting a webpage are custom fonts. There are many great techniques for lazy loading fonts to improve performance for those on poor connections. By getting insight into what fonts the user has available, we can avoid loading custom fonts. That’s where queryLocalFonts comes in — an native JavaScript function to gather user font information. queryLocalFonts is an async function that requires user permission via a browser prompt when first executed. queryLocalFonts returns an array of FontData objects which contain information about all available fonts: const localFonts = await window.queryLocalFonts(); // [FontData, FontData, ...] /* { family:... more → Posted in: JavaScript Tagged with: queryLocalFonts
ColdFusion Component for Adobe Acrobat Services / / No Comments Last month, I wrote up a post demonstrating how to use Adobe Acrobat Services with ColdFusion. This week I took some of the code I had written for that post and turned it into a proper GitHub project. You can find the latest code here: https://github.com/cfjedimaster/coldfusion-cfc-acrobat-services To use this, you’ll need credentials, which you can get and use for free for up to 500 transactions. (The docs go into detail about how that works.) Currently I only have a subset of our APIs supported, but I plan to hit most of the rest in the next day or so. To give you an example of how it works, here’s a sample that uses our Extract API. First, you instantiate the component with your... more → Posted in: JavaScript Tagged with: Acrobat, Adobe, ColdFusion, Component, Services
The AI Diplomacy Map / / No Comments According to the interactive map Deeplomacy the “relationship between Iraq and the United States has been turbulent, complex, and marked by periods of conflict and cooperation.” Deeplomacy also informs me that the relationship between Russia and Ukraine has recently “drastically worsened”.Deeplomacy is a new map tool which can explain the historical and current diplomatic relationships between Maps Mania… more → Posted in: Interactive Maps Tagged with: Diplomacy
JavaScript waitFor Polling / / No Comments As more of the JavaScript developers write becomes asynchronous, it’s only natural to need to wait for conditions to be met. This is especially true in a world with asynchronous testing of conditions which don’t provide an explicit await. I’ve written about waitForever, waitForTime, and JavaScript Polling in the past, but I wanted to have a more modern way of awaiting a given state. Let’s have a look at this super useful waitFor function! waitFor is an async function that allows developers to provide a condition function, polling interval (in milliseconds), and optional timeout (in milliseconds). // Polls every 50 milliseconds for a given condition const waitFor = async... more → Posted in: JavaScript Tagged with: JavaScript, Polling, waitFor
Neighborhood Colors / / No Comments Kiezcolors is an interactive map which shows the distribution of land use in Berlin neighborhoods. On the map areas are colored to show whether they are used for business, housing, roads, nature etc. Alongside the street map a tree-map is also used to show the percentage of land used by each category within the highlighted area (the circle of ‘undefined’ radius). You can use the map’s Maps Mania… more → Posted in: Interactive Maps Tagged with: Colors, neighborhood