Comparing version 1.1.2 to 1.1.3
@@ -1,3 +0,7 @@ | ||
# How to contribute | ||
# Contributing to MathJSLab | ||
The following is a set of guidelines for contributing to the MathJSLab | ||
package. These are mostly guidelines, not rules. Use your best judgment and | ||
feel free to propose changes to this document in a pull request. | ||
I'm really glad you're reading this, because we need volunteer developers to | ||
@@ -7,9 +11,22 @@ help this project come to fruition. At end of this file there is | ||
## Testing | ||
#### Table Of Contents | ||
The tests are run by jest. Add tests for the new code you create. | ||
* [Code of Conduct](#code-of-conduct) | ||
* [How to Contribute](#how-to-contribute) | ||
* [Community](#community) | ||
* [Code conventions](#code-conventions) | ||
* [References](#references) | ||
## Submitting changes | ||
# Code of Conduct | ||
Please send a [GitHub Pull Request to mathjslab](https://github.com/sergiolindau/mathjslab/pull/new/master) | ||
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). | ||
By participating, you are expected to uphold this code. Please report | ||
unacceptable behavior to [sergiolindau@gmail.com](mailto:sergiolindau@gmail.com). | ||
## How to Contribute | ||
Check for similar previous [issues](https://github.com/sergiolindau/mathjslab/issues) before send you own. | ||
Please send a [GitHub Pull Request to MathJSLab](https://github.com/sergiolindau/mathjslab/pull/new/main) | ||
with a clear list of what you've done (read more about | ||
@@ -27,2 +44,4 @@ [pull requests](http://help.github.com/pull-requests/)). Please follow our | ||
The tests are run by jest. Add relevant tests for the new code created. | ||
## Community | ||
@@ -34,8 +53,24 @@ | ||
## Coding conventions | ||
## Code conventions | ||
Start reading our code and you'll get the hang of it. We optimize for readability: | ||
All code is linted with [Prettier](https://prettier.io/). | ||
Start reading our code and you'll get the hang of it. In summary, we adopted: | ||
* We indent using four spaces for code files and two spaces for json files, set by EditorConfig. | ||
* We ALWAYS put spaces after list items and method parameters (`[1, 2, 3]`, not `[1,2,3]`), around operators (`x += 1`, not `x+=1`), and around hash arrows. | ||
* Prefer the object spread operator (`{...anotherObj}`) to `Object.assign()`. | ||
* Inline exports with expressions whenever possible: | ||
```typescript | ||
// Use this: | ||
export default class ClassName { | ||
} | ||
// Instead of: | ||
class ClassName { | ||
} | ||
export default ClassName | ||
``` | ||
* This is an [open source software](https://en.wikipedia.org/wiki/Open-source_software). Consider the people who will read your code, and make it look nice for them. | ||
@@ -48,2 +83,4 @@ | ||
Here are some references consulted to carry out this project. | ||
* [Decimal.js documentation](https://mikemcl.github.io/decimal.js/) | ||
@@ -59,2 +96,3 @@ * [Wolfram MathWorld](https://mathworld.wolfram.com/) | ||
* [GNU Octave Documentation](https://docs.octave.org/latest/) | ||
* [Octave Function List](https://octave.sourceforge.io/octave/overview.html) | ||
* [Octave Online](https://octave-online.net/) | ||
@@ -61,0 +99,0 @@ * [Octave scripts source](https://github.com/gnu-octave/octave/tree/default/scripts) |
{ | ||
"name": "mathjslab", | ||
"version": "1.1.2", | ||
"version": "1.1.3", | ||
"description": "MathJSLab - An interpreter with language syntax like MATLAB/Octave. ISBN 978-65-00-82338-7", | ||
"main": "build/mathjslab.js", | ||
"types": "build/src/index.d.ts", | ||
"main": "lib/mathjslab.js", | ||
"types": "lib/src/lib.d.ts", | ||
"repository": { | ||
@@ -49,3 +49,3 @@ "type": "git", | ||
"build": "webpack --mode production", | ||
"clean": "rimraf build src/parser.js", | ||
"clean": "rimraf lib src/parser.js", | ||
"publish-mathjslab": "npm publish --access public" | ||
@@ -59,7 +59,7 @@ }, | ||
"@types/jest": "29.5.5", | ||
"@types/node": "^20.8.2", | ||
"@types/node": "^20.8.3", | ||
"@types/supertest": "^2.0.14", | ||
"@types/webpack": "^5.28.3", | ||
"@typescript-eslint/eslint-plugin": "^6.7.4", | ||
"eslint": "^8.50.0", | ||
"eslint": "^8.51.0", | ||
"eslint-config-prettier": "^9.0.0", | ||
@@ -74,3 +74,3 @@ "eslint-plugin-import": "^2.28.1", | ||
"ts-jest": "29.1.1", | ||
"ts-loader": "^9.4.4", | ||
"ts-loader": "^9.5.0", | ||
"ts-node": "^10.9.1", | ||
@@ -77,0 +77,0 @@ "typescript": "^5.2.2", |
@@ -5,3 +5,3 @@ # MathJSLab | ||
[![DOI](https://zenodo.org/badge/606645564.svg)](https://zenodo.org/badge/latestdoi/606645564) | ||
[![MIT License](https://img.shields.io/badge/License-MIT-brightgreen.svg)](https://github.com/sergiolindau/mathjslab/blob/master/LICENSE) | ||
[![MIT License](https://img.shields.io/badge/License-MIT-brightgreen.svg)](https://github.com/sergiolindau/mathjslab/blob/main/LICENSE) | ||
@@ -35,4 +35,5 @@ > An interpreter with language syntax like [MATLAB®](https://www.mathworks.com/)/[Octave](https://www.gnu.org/software/octave/) written in [Typescript](https://www.typescriptlang.org/). | ||
A functional [demo](https://mathjslab.netlify.app/) use of this package in a Web | ||
application can be found [here](https://github.com/sergiolindau/mathjslab-calculator). | ||
A functional [demo](https://mathjslab.netlify.app/) use of this package in a | ||
[Web application](https://en.wikipedia.org/wiki/Web_application) can be found | ||
[here](https://github.com/sergiolindau/mathjslab-calculator). | ||
@@ -39,0 +40,0 @@ ## Features |
@@ -433,3 +433,3 @@ /** | ||
*/ | ||
private aliasName: (name: string) => string = (name: string): string => name; | ||
public aliasName: (name: string) => string = (name: string): string => name; | ||
@@ -436,0 +436,0 @@ /** |
{ | ||
"extends": "./tsconfig.json", | ||
"exclude": ["node_modules", "webpack.config.ts", "test", "build", "**/*spec.ts"] | ||
"exclude": ["node_modules", "webpack.config.ts", "test", "lib", "**/*spec.ts"] | ||
} |
@@ -16,3 +16,3 @@ { | ||
// "lib": [], /* Specify a set of bundled library declaration files that describe the target runtime environment. */ | ||
// "jsx": "react", /* Specify what JSX code is generated. */ | ||
// "jsx": "react", /* Specify what JSX code is generated. */ | ||
// "experimentalDecorators": true, /* Enable experimental support for TC39 stage 2 draft decorators. */ | ||
@@ -53,3 +53,3 @@ // "emitDecoratorMetadata": true, /* Emit design-type metadata for decorated declarations in source files. */ | ||
// "outFile": "./", /* Specify a file that bundles all outputs into one JavaScript file. If 'declaration' is true, also designates a file that bundles all .d.ts output. */ | ||
"outDir": "./build", /* Specify an output folder for all emitted files. */ | ||
"outDir": "./lib", /* Specify an output folder for all emitted files. */ | ||
// "removeComments": true, /* Disable emitting comments. */ | ||
@@ -56,0 +56,0 @@ // "noEmit": true, /* Disable emitting files from a compilation. */ |
@@ -5,3 +5,3 @@ import path from 'path'; | ||
const config: webpack.Configuration = { | ||
entry: './src/index.ts', | ||
entry: './src/lib.ts', | ||
module: { | ||
@@ -30,3 +30,3 @@ rules: [ | ||
output: { | ||
path: path.resolve(__dirname, 'build'), | ||
path: path.resolve(__dirname, 'lib'), | ||
filename: 'mathjslab.js', | ||
@@ -33,0 +33,0 @@ library: 'mathjslab', |
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 1 instance in 1 package
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 1 instance in 1 package
430114
33
172