I have recently added custom migrations to the following packages and therefore thought that it was about time that I mentioned them:
There is not much more to add here as the readme files say it all.
I should also mention of the following two packages:
I use the Necessary package in nearly all of my projects, the only exceptions being ones where I make a point of not having any dependencies at all. The Sufficient package on the other hand is only used in a few. Still, it provides controller functionality and an overall architecture to those projects in a few lines of code, contrasting with monolithic frameworks that often struggle to provide the same with tens of thousands. I wrote a little about this on the Juxtapose site here.
Update: I have recently been working on Murmuration again, adding a way to generate statements rather than relying on static SQL files. This has worked out surprisingly well and reminds me of the tine I moved over to programmatic styles from SASS, which I wrote about in an earlier update. I am also glad because Murmuration now seems to have a definite purpose. It seemed a bit rudderless before. Anyway, I could go on about it here, but it is probably best to just point you in the direction of the readme file again.
This is another of those updates that comes with a bit of a health warning. You should probably only read on if you are interested in front-end programming, React in particular. Here is a link to the package that I will be referring to:
React's mixins differ slightly from the above. They are assigned specifically to class instances rather than generally to the classes themselves. This is going to be slower, for a start, moreover it used to be the case that mixins could not be avoided. Either you used a mixin to define a method in certain cases, or you had to make do without. So why did React implement mixins in this way? Take a look at part of Reaction's React.createElement() function here. You can see that the underlying ReactFunctionElement class is instantiated and then passed the function referenced in the JSX. The function itself is not invoked immediately, however. This happens only when the underlying element is mounted. It appears that React adopted a similar pattern in order to support either calling the React.createClass() function or extending the Component class. In both cases a corresponding underlying element class is instantiated and passed a suitable reference, see here for the equivalent in Reaction. It was this dichotomy that seemed to have resulted in the need for React's mixins, which bind functions to instances of these underlying element classes as ooposed to, say, instances of subclasses of the Component class.
Now you could argue that all of the above is a bit unconvincing. After all, in has been possible to define methods in subclasses of the Component class for years. My excuse is I could not get Reaction to work all those years ago without the aforementioned dichotomy and that React's mixins ratified it at the time.
Anyway, recently I have been working on the Open Mathematics site again, which uses Reaction, and have gotten increasingly fed up with React's mixins. So I wondered whether it would be possible to do away with them, as React had done. The obvious solution was to merge the Component class and the underlying ReactComponentElement class into one and then instantiate just the subclasses of the former, see here. And this worked! It worked because it is not the instantiation of the subclass of the Component class that is deferred until mounting, it is always instantiated immediately, but only the invocation of its render() method.
So now you can extend the Component class and define methods in your subclass, just like React. Reaction still does not support diffing, and therefore remains quite a different experience to React, but still.
Here are links to two other packages related to Reaction:
I think that between them they now constitute a viable alternative to the combination of React, Redux and Styled components, although I remain a big fan of the latter.
I have just finished writing a couple of new Easy packages as well as rewriting some the existing ones, so this seems like a good time to list them:
I have also just had another go at the Juxtapose website, so I am shamelessly plugging it again:
I think it conveys Juxtapose a little better although there is, of course, always room for improvement...
I have just made what I hope is a good fist of the Juxtapose website. You can find the link in the websites section below. Here is it again, I guess for emphasis:
As I mentioned in my previous update, I am a big fan of programmatic styles and JSX, which is partly why I have made this renewed effort.
Both the Occam website and the Occam IDE (such as it is) are written with Juxtapose and programmatic styles.
Update: I have also been working on a pretty printer:
Essentially it is a simpler version of the Occam IDE's pretty printer and it incorporates several of the Occam grammar packages. You can see about a dozen instances of it on the Juxtapose website.
You probably should not read this unless you think CSS is interesting.
I have been programming with CSS since the late nineties, and for most of that time I have had the distinct feeling that I did not really know what I was doing. I certainly tried to do a good job, but a glance at the CSS I produced would invariably suggest otherwise. And when I looked at other people's CSS, it appeared that they did not have much of a clue either.
Everyone will have their opinions on why CSS is so intractable. Here is my tuppence worth:
Actually the situation is much better these days. And one thing that I did manage to figure out over the years was that the above deficiencies were not actually the root cause of bad CSS. The problem was what can best be described as an organisational one. The nature of CSS selectors meant that you always ended up with a cat's cradle of interrelations between styles and therefore the way they affected any particular HTML element was often anyone's guess.
Then SASS came along and things got better. I think SASS gave us three invaluable things:
These things can lead to better organised code in a shallow, syntactic sense. Crucially, however, they also encourage and facilitate a more modular approach fundamentally. I eventually came to the following conclusion, in fact:
CSS selectors should not be indicative of and encapsulate any specific collection of properties, and then be applied generally. Instead, they should be used solely to target specific kinds of HTML elements, and should only encapsulate that kind of element's requisite properties.
It took me twenty years to figure this out.
Together with JSX, I think programmatic styles are game changer for front-end programming. There will no doubt always be debate about the architecture of large web applications, but in my opinion the presentation side of things is now a done deal for several years to come.
Here are some new build tools:
None of them are any great shakes, to be honest, but they have brought the build times for my projects down from the often seemingly interminable to the reasonably acceptable.
Update: I have spent the last several months improving these tools. Here is a summary:
The big one here is the support for SWC and ESBuild. I have actually migrated all of my projects over to these tools and the result is that build times have generally improved by a factor of ten or more.
I have finally gotten to grips with eliminating left recursion from BNF. It was all a bit much for a readme file, so I wrote a paper:
The implementation is in Occam's grammar utilities package, a link to which can be found in the resources section.
Recently I learned about 996.ICU. Several months after everybody else, probably. Anyway, it gave me the excuse to run through my open source projects and refresh their licenses, which I have now done. The standard MIT license that I use for all of these projects bar Occam is very amenable to the inclusion of the Anti-996 license. See here, for example. I also merged the standard Apache and Anti-996 licenses for Occam into one license, which can be found here. Feel free to lift either of these licenses for your own projects, obviously.
I have finally finished the new version of Occam. There is even a macOS version.
Update: As of version 2.3 there is Fira Code support!
I decided last year that I should get anything related to Occam's verification into the public domain. With this in mind I have released some new packages concerned with Occam's grammars and its document object model. Specifically:
These links can also be found in the updated resources section.
Update: This one has also been added recently:
I have just published an implementation of the Concur algorithm.
You can find a link at the foot of the resources section, too.
Earlier this year I was kindly invited out to France to meet with others interested in formal mathematics. I ended up giving an impromptu talk and have just gotten around to completing the slides that would have gone with it. You can find them in the new presentations section below.
I should take this opportunity to sincerely thank Josef Urban and Henk Barendregt for their interest in Occam.
I have been working on the Open Mathematics website again. You can now make changes to package's readme files and publish them directly from the website. Other than that there is now some support for GitHub. Specifically, you can commit the aforementioned changes to readme files to underlying GitHub repository at the same time as publishing; you can edit and create issues; and you can do the same for comments on issues. There is also support for TeX, which can be added to readme files, issues and comments.
The result is that the website now functions at least partially as a kind of maths enabled, GitHub overlay. You can compare the readme file of the 'minimal-propositional-logic' package across the two sites here and here to get an idea.
There is a new website for publishing Occam packages as well as a command line package management tool to enable you to do so, called Open Mathematics. You can find a link to it in the websites section below.
Last updated 18th June 2022