From c65d08c99eb7807699e40d9980a3e9801ecf7f55 Mon Sep 17 00:00:00 2001 From: falcon027 Date: Wed, 30 Sep 2020 13:42:17 +0200 Subject: [PATCH] Update README I added a hint about how to import the module which could be helpful for Beginners. --- README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 0b089f7..0a7b089 100644 --- a/README.md +++ b/README.md @@ -15,6 +15,10 @@ npm install equations #### Examples: ```javascript +//import + +const Equation = require('equations').default + // solve console.log(Equation.solve('4 * lg(4) ^ 3')); // 32 @@ -77,7 +81,7 @@ Options: #### registerConstant(key: String, value: Function/Number) Registers a new constant. value can be a function (takes no arguments), or a constant number. -That's right, we have named these *constants* but they actually can change, that's why we can use functions to define them. An example is the `RAND` constant which calls `Math.random`. +That's right, we have named these *constants*, but they actually can change, that's why we can use functions to define them. An example is the `RAND` constant which calls `Math.random`. Contributing ============