GithubHelp home page GithubHelp logo

Comments (9)

gusbemacbe avatar gusbemacbe commented on May 31, 2024 1

Hello @Mogztter

Here is small tutorial done by @yyyc514:

highlightjs/highlight.js#2328

Or the quick snippet:

git clone https://github.com/highlightjs/highlight.js
git checkout squash_build_pipeline

npm install

mkdir extra
cd extra
git clone https://github.com/highlightjs/highlightjs-cypher
cd ..

node ./tools/build.js -t browser :common cypher

// or

node  --stack-size=65500  ./tools/build.js -t cdn

from highlightjs-cypher.

ggrossetie avatar ggrossetie commented on May 31, 2024

Alright, so if I understand correctly, we should rely on the main repository (highlightjs/highlight.js) to generate the dist: #2 (comment).

We should probably add the procedure to the README (once the branch squash_build_pipeline is merged).

from highlightjs-cypher.

gusbemacbe avatar gusbemacbe commented on May 31, 2024

@Mogztter

Actually I wanted to minify the Cypher files. But you did.

from highlightjs-cypher.

joshgoebel avatar joshgoebel commented on May 31, 2024

Alright, so if I understand correctly, we should rely on the main repository (highlightjs/highlight.js) to generate the dist:

Yes, though eventually perhaps we need a nicer way of doing it. :-)

from highlightjs-cypher.

gusbemacbe avatar gusbemacbe commented on May 31, 2024

I think node --stack-size=65500 ./tools/build.js -t cdn generates and minify a CYpher file. Let us see @yyyc514's answer.

from highlightjs-cypher.

joshgoebel avatar joshgoebel commented on May 31, 2024

It builds a FULL CDN build of all languages (including all 3rd party ones in extra) and it places the 3rd party distributables into the dist folder automagically.

from highlightjs-cypher.

gusbemacbe avatar gusbemacbe commented on May 31, 2024

Ah, I got.

@Mogztter, please make a PR and add the minified files from the folder dist.

from highlightjs-cypher.

ggrossetie avatar ggrossetie commented on May 31, 2024

Yes, though eventually perhaps we need a nicer way of doing it. :-)

@yyyc514 I think it would be useful if we could generate the dist without a local copy of the highlightjs repository.
I believe it should be possible to create a npm package of the build scripts?

npm i highlightjs-tools-build --save-dev
const builder = require('highlightjs-tools-build')
builder.build('/path/to/repository')

Or we could provide a binary:

"scripts": {
  "dist": "highlightjs-build -t cdn ."
}

Wdyt?

from highlightjs-cypher.

joshgoebel avatar joshgoebel commented on May 31, 2024

Long-term, yes. Though there is no great way to run the FULL test suite (auto-detect tests) that way... I don't think I'd want to release a WHOLE other npm package... that means it's probably be the existing npm package that expanded, but I'm not sure we want ALL the test bits in there. Haven't given it a lot of thought.

from highlightjs-cypher.

Related Issues (9)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.