Sharing Assets Offline and Online
I have several websites and I want them to share common assets - For now, at least a global css file. As this must be a common challenge, I anticipate there will be several different ways to achieve the end as well as several different opinions as to which is the best strategy.
My preference would be to have some mechanism setup to "clone-link" the css files in 2 separate projects, so that changes in one file are imposed on the other. Then I would still be able to work in the confines of a single project at a time.
An alternative, I can envisage, would be to have seperate projects \ websites link to a common css file which is served by one of the projects. Working offline, I know I can link an HTML files to a css file anywhere on the harddrive. But that would mean linking an HTML file to a css file that is outside the project folder and once the project is posted online, that outside link would be useless. I'm expect there is a smart, i.e. automated, way to change the css-link (or whatever) to a specific web-address, (such as one of my sites) in the process of uploading. For example: when working offline, I can have the HTML files in mysite2 link to D:\Webs\mysite1\global.css. Then, once posted, the links change to www.mysite1\global.css. I imagine this can be achieved quite neatly with a js script, but I am only just getting into jas and, as yet, don't know where to start.
All help and opinions much appreciated. Just please don't mention Bootstrap (I have a peverse need to do it my way). 🙂
