-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bundling new (existing) languages with the default ("common") CDN build #2206
Comments
After we have a more refined build process I'm still interested in releasing a LARGER build also... and then I'd throw a bunch of other things in there that aren't huge but you've probably heard of. That build idea is currently running around 135kb. |
@egor-rogov Any objections to a "Highlight.js already has support for KOTLIN, are you loading an extra language file that you now no longer need?" in console.log for people who upgrade but don't remove the extra JS reference they now no longer need? Would that be helpful or noisy? |
Umm, what is that extra reference you are talking about? |
Right now if they are loading an extra js file from the CDN to support these languages. After this they would be just wasting time and bandwidth. |
So it's true not only for Kotlin, but also for any other "promoted" language. |
Yes. Well often it’s a visitor seeing the content. Not the sites author. You don’t want to break their experience. Red error messages would be a bad look for what isn’t a serious problem. Just annoying. |
It may be yellow, not red (: And disappear in several second, for example. |
The only two choices in my opinion are console output or nothing - not some sort of visual thing. I agree it's probably mostly useless. :-) It would have to be a VERY serious problem before I'd bother a sites readers/users about it. |
Agree, but it won't be harmful either.
Then it's about making the console output appealing somehow — e.g. to style the console output element to mimic the look of a real shell window, with borders, a scroll bar, a top bar, monospaced font, etc. Something along the lines of the consoles shown here:
It could then be perceived as a way to represent the build process in the browser. For users who are not interested in it (and don't understand it), it might be a way to get a feel of how the building process looks like from the developers' perspective. For those who are acquainted with the nitty-gritty of HJS build system, it might provide real-time useful information. |
Are we reading the same issue? Lol. This is about how to best communicate to a developer whose using highlightjs that they may need to change their code to include a few less files. But the developer typically isn’t the one reading the webpage. It’s some random Joe who definitely doesn’t need to be bothered about this. I thought a console item might be nice for the more attention to detail developers who care about such things. I know they are out there. |
@egor-rogov Since we'll find it MUCH harder to remove languages than to add them I'm going to yank R and Dockerfile. Leaving the adds:
Easy enough to add more later and this feels a little more tightly focused. Pretty soon I also want to see about having a "larger" prebundle, so that should reduce pressure to keep adding things to the smaller bundle. If someone wants "the kitchen sink" they should use a larger bundle (where we could throw in all the popular functional languages, etc). |
Hmm, aren't they quite popular? No fundamental objections, though. |
HAHAHAH, now you want to weigh in after saying it was up to me? :-) I'm not sure... but they don't feel "general" to me... if I could go back I'd likely remove Apacha/Nginx from the default bundle, feels a little "system"... but my point was it's gonna prove harder to take things out - and no one here is clamoring for anything. So I say be a little more conservative. If someone comes along pushing for one or the other we can always add them in the next release. :-) |
Nope. Just had to reply somehow since you mentioned me in your comment (: |
Ah. It was just a heads up. Closing with #2204. |
Currently the plan is to include the following new languages:
.. and to remove none.
This brings the default bundled size up from 50kb (CDN copy) to around 75kb or so (which still seems trivial to me, since it's pre-gzip). Powershell was on the possible list but weighs in itself at a whopping 35kb (so many keywords). Once we decide to add them we're probably stuck with them for quite a while...
If anyone would like to share any thoughts, feel free. There is additional discussion here: #1119
I created a new issue for a bit more visibility.
Plan is to sort this out soon so the 9.15.11 release would include these new options and have a larger file size.
The text was updated successfully, but these errors were encountered: