mirror of
https://github.com/Smaug123/KaTeX
synced 2025-10-05 19:28:39 +00:00
Summary: Make our own parser that doesn't use jison, so that we can handle funny TeX syntax, and to make it smaller. Test Plan: Make sure the tests pass with the new parser. Reviewers: alpert Reviewed By: alpert Differential Revision: http://phabricator.khanacademy.org/D3029
25 lines
496 B
Makefile
25 lines
496 B
Makefile
.PHONY: build copy serve clean
|
|
build: build/katex.js
|
|
|
|
compress: build/katex.min.js
|
|
@echo -n "Minified, gzipped size: "
|
|
@gzip -c $^ | wc -c
|
|
|
|
build/katex.js: katex.js Parser.js Lexer.js
|
|
./node_modules/.bin/browserify $< --standalone katex > $@
|
|
|
|
build/katex.min.js: build/katex.js
|
|
uglifyjs --mangle < $< > $@
|
|
|
|
|
|
copy: build
|
|
cp build/katex.js ../exercises/utils/katex.js
|
|
cp static/katex.css ../exercises/css/
|
|
cp -R static/fonts ../exercises/css/
|
|
|
|
serve:
|
|
node server.js
|
|
|
|
clean:
|
|
rm -rf build/*
|