Skip to content

Commit

Permalink
3.1.0 Move to cdnjs
Browse files Browse the repository at this point in the history
- MathJax CDN shutting down on April 30, 2017
  https://www.mathjax.org/cdn-shutting-down/
- Change loadComplete, remove [Contrib]
  mathjax/MathJax-third-party-extensions#39
- Prepare to move to cdnjs
  • Loading branch information
mhchem committed Apr 11, 2017
1 parent da46b35 commit fae3ec0
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 15 deletions.
2 changes: 0 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
language: node_js
node_js:
- node
before_install:
- cd mhchem
install:
- npm install
script:
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# MathJax/mhchem Extension 3.0
# MathJax/mhchem Extension 3.1

mhchem 3.0 is a 3rd-party extension to MathJax for typesetting chemical equations.
mhchem 3.1 is a 3rd-party extension to MathJax for typesetting chemical equations.


## Usage
Expand Down
4 changes: 2 additions & 2 deletions mhchem.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
MathJax.Extension["TeX/mhchem"]={version:"3.0.6"},MathJax.Hub.Register.StartupHook("TeX Jax Ready",
MathJax.Extension["TeX/mhchem"]={version:"3.1.0"},MathJax.Hub.Register.StartupHook("TeX Jax Ready",
function(){var n=MathJax.InputJax.TeX,r=MathJax.Object.Subclass({string:"",Init:
function(n){this.string=n},Parse:
function(r){try{return o.go(t.go(this.string,r))}catch(r){n.Error(r)}}}),t={};t.go=
Expand Down Expand Up @@ -332,5 +332,5 @@ null,!0),MathJax.Hub.Register.StartupHook("TeX AMSmath Ready",
function(){n.Definitions.Add({macros:{xleftrightarrow:["xArrow",8596,6,6],xrightleftharpoons:["xArrow",8652,5,7],xRightleftharpoons:["xArrow",8652,5,7],xLeftrightharpoons:["xArrow",8652,5,7]}},
null,!0)}),n.Parse.Augment({CE:
function(n){var t=this.GetArgument(n),o=r(t).Parse();this.string=o+this.string.substr(this.i),this.i=0},PU:
function(n){var t=this.GetArgument(n),o=r(t).Parse("pu");this.string=o+this.string.substr(this.i),this.i=0}}),MathJax.Hub.Startup.signal.Post("TeX mhchem Ready")}),MathJax.Ajax.loadComplete("[Contrib]/mhchem/mhchem.js");
function(n){var t=this.GetArgument(n),o=r(t).Parse("pu");this.string=o+this.string.substr(this.i),this.i=0}}),MathJax.Hub.Startup.signal.Post("TeX mhchem Ready")}),MathJax.Ajax.loadComplete("[mhchem]/mhchem.js");

23 changes: 16 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,16 +1,25 @@
{
"name": "mathjax-mhchem-test",
"version": "1.0.0",
"description": "Test suite for MathJax/mhchem extension",
"scripts": {
"test": "tape tests/*.js"
},
"author": "Martin Hensel",
"name": "mathjax-mhchem",
"filename": "mhchem.js",
"version": "3.1.0",
"description": "mhchem extension for MathJax",
"keywords": [
"MathJax",
"LaTeX",
"Chemistry"
],
"license": "Apache-2.0",
"contributors": [
"Martin Hensel",
"The MathJax Consortium"
],
"repository": {
"type": "git",
"url": "git://github.com/mhchem/MathJax-mhchem.git"
},
"scripts": {
"test": "tape tests/*.js"
},
"devDependencies": {
"tape": "^4.0.3",
"request": "^2.74.0"
Expand Down
4 changes: 2 additions & 2 deletions unpacked/mhchem.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@


MathJax.Extension["TeX/mhchem"] = {
version: "3.0.6"
version: "3.1.0"
};

MathJax.Hub.Register.StartupHook("TeX Jax Ready",function () {
Expand Down Expand Up @@ -1712,4 +1712,4 @@ MathJax.Hub.Register.StartupHook("TeX Jax Ready",function () {

});

MathJax.Ajax.loadComplete("[Contrib]/mhchem/unpacked/mhchem.js");
MathJax.Ajax.loadComplete("[mhchem]/unpacked/mhchem.js");

0 comments on commit fae3ec0

Please sign in to comment.