EDIT: other answers point to base16 as a way to do this automatically. Use that. Leaving my previous comment here just in case.
I think what the creator is doing is outsourcing the maintenance of each individual app to a maintainer that cares; the themes folder contains pointers to other repos:
This could be used to "reverse-engineer a generic platform" relatively easily:
1: Fork Dracula and its themes
3: For each color in Dracula.Palette
4: Find and replace color.hex by color.refjex on themes
5: Find and replace "color.r,color.g,color.b" by color.refrgb on themes
6: Find and replace "color.h,color.s,color.l" by color.refhsl on themes
The whole idea would be replacing #282a36 for a reference like `{{Background}}` and then using a templating language like handlebars or m4 to generate the themes.
Of course steps 4,5 and 6 are more complex than 3 lines. One will have to come up with a way to filter out spaces, commas and other things. I expect a lot of the apps out there to expect hex numbers though.
I think what the creator is doing is outsourcing the maintenance of each individual app to a maintainer that cares; the themes folder contains pointers to other repos:
https://github.com/dracula/dracula-theme/tree/master/themes
I think that is a good idea.
This could be used to "reverse-engineer a generic platform" relatively easily:
The whole idea would be replacing #282a36 for a reference like `{{Background}}` and then using a templating language like handlebars or m4 to generate the themes.Of course steps 4,5 and 6 are more complex than 3 lines. One will have to come up with a way to filter out spaces, commas and other things. I expect a lot of the apps out there to expect hex numbers though.