Skip to content

Commit

Permalink
Initial Commit
Browse files Browse the repository at this point in the history
  • Loading branch information
sergiolindau committed Sep 30, 2024
1 parent 87cf67f commit c76af02
Show file tree
Hide file tree
Showing 7 changed files with 42 additions and 45 deletions.
4 changes: 4 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
All notable changes to this project will be documented in this file.
This project adheres to [Semantic Versioning](http://semver.org/).

## 1.6.0
- Change repository owner to MathJSLab GitHub organization: https://github.com/MathJSLab .
Changes in repository references in 'package.json' file and documentation.

## 1.5.13
- Changes in 'README.md' file (CDN instructions and links, badges, build
instructions, ISBN link, etc.).
Expand Down
2 changes: 1 addition & 1 deletion CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ representative at an online or offline event.

Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported to the community leaders responsible for enforcement at
[email protected].
[[email protected]](mailto:[email protected]).
All complaints will be reviewed and investigated promptly and fairly.

All community leaders are obligated to respect the privacy and security of the
Expand Down
14 changes: 7 additions & 7 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ I'm really glad you're reading this, because we need volunteer developers to
help this project come to fruition.

All notable changes to this project will be documented in
[CHANGES.md](https://github.com/sergiolindau/mathjslab/blob/main/CHANGES.md) file.
[CHANGES.md](https://github.com/MathJSLab/mathjslab/blob/main/CHANGES.md) file.

Please consider contributing to the [MathJSLab Calculator](https://github.com/sergiolindau/mathjslab-calculator)
project, which is the standard use case of the [MathJSLab](https://github.com/sergiolindau/mathjslab).
See the [Work fronts](#work-fronts) section in the [CONTRIBUTING.md](https://github.com/sergiolindau/mathjslab/blob/main/CONTRIBUTING.md)
Please consider contributing to the [MathJSLab Calculator](https://github.com/MathJSLab/mathjslab-calculator)
project, which is the standard use case of the [MathJSLab](https://github.com/MathJSLab/mathjslab).
See the [Work fronts](#work-fronts) section in the [CONTRIBUTING.md](https://github.com/MathJSLab/mathjslab/blob/main/CONTRIBUTING.md)
file for each project to see which project your contribution fits into.

This project has an ISBN assigned to it. Whenever significant changes are made
Expand All @@ -34,15 +34,15 @@ The project page is at [mathjslab.com](https://mathjslab.com/) with a demo Web A
## Code of Conduct

This project and everyone participating in it is governed by the
[MathJSLab Code of Conduct](https://github.com/sergiolindau/mathjslab/blob/main/CODE_OF_CONDUCT.md).
[MathJSLab Code of Conduct](https://github.com/MathJSLab/mathjslab/blob/main/CODE_OF_CONDUCT.md).
By participating, you are expected to uphold this code. Please report
unacceptable behavior to [[email protected]](mailto:[email protected]).

## How to Contribute

Check for similar previous [issues](https://github.com/sergiolindau/mathjslab/issues) before send your own.
Check for similar previous [issues](https://github.com/MathJSLab/mathjslab/issues) before send your own.

Please send a [GitHub Pull Request to MathJSLab](https://github.com/sergiolindau/mathjslab/pull/new/main)
Please send a [GitHub Pull Request to MathJSLab](https://github.com/MathJSLab/mathjslab/pull/new/main)
with a clear list of what you've done (read more about
[pull requests](http://help.github.com/pull-requests/)). Please follow our
coding conventions (below) and make sure all of your commits are atomic (one
Expand Down
56 changes: 25 additions & 31 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@

[![NPM Version](https://img.shields.io/npm/v/mathjslab)](https://www.npmjs.com/package/mathjslab)
[![Website](https://img.shields.io/website?url=https%3A%2F%2Fmathjslab.com%2F)](https://mathjslab.com/)
[![GitHub Created At](https://img.shields.io/github/created-at/sergiolindau/mathjslab-calculator)](https://github.com/sergiolindau/mathjslab)
[![NPM License](https://img.shields.io/npm/l/mathjslab)](https://github.com/sergiolindau/mathjslab/blob/main/LICENSE)
[![GitHub Created At](https://img.shields.io/github/created-at/MathJSLab/mathjslab)](https://github.com/MathJSLab/mathjslab)
[![MIT License](https://img.shields.io/npm/l/mathjslab)](https://github.com/MathJSLab/mathjslab/blob/main/LICENSE)
[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.8396265.svg)](https://doi.org/10.5281/zenodo.8396265)
[![ISBN](https://img.shields.io/badge/ISBN-978--65--00--82338--7-green?style=flat&link=https://grp.isbn-international.org/search/piid_solr?keys=978-65-00-82338-7)](https://grp.isbn-international.org/search/piid_solr?keys=978-65-00-82338-7)
[![NPM Downloads](https://img.shields.io/npm/d18m/mathjslab)](https://www.npmjs.com/package/mathjslab)
[![jsDelivr hits (npm)](https://img.shields.io/jsdelivr/npm/hy/mathjslab)](https://www.jsdelivr.com/package/npm/mathjslab)
[![Libraries.io SourceRank](https://img.shields.io/librariesio/sourcerank/npm/mathjslab)](https://libraries.io/npm/mathjslab)
[![Libraries.io SourceRank](https://img.shields.io/librariesio/sourcerank/npm/mathjslab)](https://libraries.io/npm/mathjslab/sourcerank)
[![NPM Bundle Size](https://img.shields.io/bundlephobia/min/mathjslab)](https://www.npmjs.com/package/mathjslab)
[![NPM Unpacked Size](https://img.shields.io/npm/unpacked-size/mathjslab)](https://www.npmjs.com/package/mathjslab)
[![Minzip Size](https://img.shields.io/bundlephobia/minzip/mathjslab)](https://www.npmjs.com/package/mathjslab)
Expand All @@ -28,8 +28,9 @@ language. It is written completely in [Typescript](https://www.typescriptlang.or

The project page with a functional demo use of this package in a
[Web application](https://en.wikipedia.org/wiki/Web_application) can be found
at [mathjslab.com](https://mathjslab.com/). The repository is
[here](https://github.com/sergiolindau/mathjslab-calculator).
at [mathjslab.com](https://mathjslab.com/). The repository is in the
[MathJSLab Organization](https://github.com/MathJSLab) on
[GitHub](https://github.com/).

It can run in browser environment and implements an arbitrary precision
arithmetics using [decimal.js](https://www.npmjs.com/package/decimal.js)
Expand Down Expand Up @@ -57,7 +58,7 @@ and environments.
- Is easily extensible through configuration parameters passed to `Evaluator` constructor.
- [Open source](https://en.wikipedia.org/wiki/Open-source_software) with fully documented code: [MIT License](https://opensource.org/license/mit).
- Includes test suite using [Jest](https://jestjs.io/) [framework](https://en.wikipedia.org/wiki/Software_framework).
- Improved demo [Web application](https://en.wikipedia.org/wiki/Web_application) at project page: [mathjslab.com](https://mathjslab.com/) ([repository](https://github.com/sergiolindau/mathjslab-calculator)).
- Improved demo [Web application](https://en.wikipedia.org/wiki/Web_application) at project page: [mathjslab.com](https://mathjslab.com/) ([repository](https://github.com/MathJSLab/mathjslab-calculator)).

## Browser support

Expand Down Expand Up @@ -128,7 +129,7 @@ that delivers content from the [npm repository](https://www.npmjs.com/).
To load [MathJSLab package](https://www.npmjs.com/package/mathjslab) through
[UNPKG](https://unpkg.com/browse/mathjslab/)
[CDN](https://en.wikipedia.org/wiki/Content_delivery_network) copy the
following [HTML](https://en.wikipedia.org/wiki/HTML) code:
following [HTML](https://developer.mozilla.org/en-US/docs/Web/HTML) code:

```html
<script src="https://www.unpkg.com/mathjslab"></script>
Expand All @@ -141,7 +142,7 @@ following [HTML](https://en.wikipedia.org/wiki/HTML) code:
To load [MathJSLab package](https://www.npmjs.com/package/mathjslab) through
[jsDelivr](https://www.jsdelivr.com/package/npm/mathjslab)
[CDN](https://en.wikipedia.org/wiki/Content_delivery_network) copy the
following [HTML](https://en.wikipedia.org/wiki/HTML) code:
following [HTML](https://developer.mozilla.org/en-US/docs/Web/HTML) code:

```html
<script src="https://cdn.jsdelivr.net/npm/mathjslab/lib/mathjslab.min.js"></script>
Expand All @@ -158,7 +159,7 @@ let evaluator = new mathjslab.Evaluator(EvaluatorConfiguration);
## Contributing

To contribute to this project see our
[contributing guidelines](https://github.com/sergiolindau/mathjslab/blob/main/CONTRIBUTING.md).
[contributing guidelines](https://github.com/MathJSLab/mathjslab/blob/main/CONTRIBUTING.md).

Join the community chat:

Expand All @@ -170,57 +171,50 @@ To build the project, you only need [Node.js&reg;](https://nodejs.org/) and
the [Java Runtime Environment](https://www.oracle.com/java/) installed. The
project build and dependencies are managed by
[npm](https://www.npmjs.com/package/npm) through scripts in the
[`package.json`](https://github.com/sergiolindau/mathjslab/blob/main/package.json)
[`package.json`](https://github.com/MathJSLab/mathjslab/blob/main/package.json)
file. The build scripts download the latest version of
[ANTLR](https://www.antlr.org/) into the resources directory for use by the
project.

The test suite uses the
[Jest](https://jestjs.io/)
project. The test suite uses the [Jest](https://jestjs.io/)
[framework](https://en.wikipedia.org/wiki/Software_framework).

* **Before building and testing** the project, to **initialize** the workspace, run:
### Build scripts

The following build scripts are defined:

1. **Before building and testing** `mathjslab`, to **initialize** the project workspace, run:
```bash
npm run update
```

This will update the dependencies, install all of them, and download the
latest version of ANTLR, preparing any resources needed to build the project.

* Run the `mathjslab` **tests**:
latest version of [ANTLR](https://www.antlr.org/), preparing any resources
needed to build the project.

2. Run the `mathjslab` **tests**:
```bash
npm run test
```

* **Format** and **lint** `mathjslab` code:

3. **Format** and **lint** `mathjslab` code:
```bash
npm run format:lint
```

* **Build** `mathjslab` package:

4. **Build** `mathjslab` package:
```bash
npm run build
```

* Workspace **cleanup**:

To clean build files use:

5. To **cleanup** all build files in workspace use:
```bash
npm run clean
```

To delete resources, `package-lock.json` file and `node_modules` directory too, use:

6. To **delete resources and dependencies**, the `package-lock.json` file and
`node_modules` directory too, use:
```bash
npm run clean:all
```

Before run this command you will need to do workspace setup running
After run this command you will need to do workspace setup running
`npm run update` again.

## Language subset
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"name": "mathjslab",
"version": "1.5.13",
"version": "1.6.0",
"description": "MathJSLab - An interpreter with language syntax like MATLAB®/Octave, ISBN 978-65-00-82338-7.",
"main": "lib/mathjslab.js",
"types": "lib/src/lib.d.ts",
"repository": {
"type": "git",
"url": "git+https://github.com/sergiolindau/mathjslab.git"
"url": "git+https://github.com/MathJSLab/mathjslab.git"
},
"keywords": [
"MathJSLab",
Expand All @@ -26,7 +26,7 @@
"author": "Sergio Lindau <[email protected]>",
"license": "MIT",
"bugs": {
"url": "https://github.com/sergiolindau/mathjslab/issues"
"url": "https://github.com/MathJSLab/mathjslab/issues"
},
"homepage": "https://mathjslab.com/",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion tsconfig.build.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"extends": "./tsconfig.json",
"exclude": ["node_modules", "eslint.config.*", "jest.config.*", "webpack.config.*", "**/*spec.ts", "lib", "res", "script"]
"exclude": ["node_modules", "eslint.config.*", "jest.config.*", "webpack.config.*", "**/*spec.*", "lib", "res", "script"]
}
3 changes: 1 addition & 2 deletions webpack.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@ import path from 'node:path';
import webpack from 'webpack';

export default (env: any, argv: any): webpack.Configuration => {
console.warn('webpack.config.ts: Building production bundle.');
console.log('Environment variables:');
console.warn(`Webpack configuration path: ${__filename}\n- Building ${argv.mode} bundle.\n- Environment variables:`);
console.table(env);
return {
mode: argv.mode,
Expand Down

0 comments on commit c76af02

Please sign in to comment.