diff --git a/.eslintignore b/.eslintignore new file mode 100644 index 0000000..1521c8b --- /dev/null +++ b/.eslintignore @@ -0,0 +1 @@ +dist diff --git a/LICENSE.md b/LICENSE.md index a5952ae..995d340 100644 --- a/LICENSE.md +++ b/LICENSE.md @@ -1,4 +1,4 @@ -Copyright (c) 2019-2020, Sideway Inc, and project contributors +Copyright (c) 2019-2020, Sideway. Inc, and project contributors All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: diff --git a/README.md b/README.md index 2cfb1c0..13da3af 100755 --- a/README.md +++ b/README.md @@ -1,20 +1,17 @@ - - -# @hapi/formula +# @sideway/formula #### Math and string formula parser. -**formula** is part of the **hapi** ecosystem and was designed to work seamlessly with the [hapi web framework](https://hapi.dev) and its other components (but works great on its own or with other frameworks). If you are using a different web framework and find this module useful, check out [hapi](https://hapi.dev) – they work even better together. +**formula** is part of the **joi** ecosystem. -### Visit the [hapi.dev](https://hapi.dev) Developer Portal for tutorials, documentation, and support +### Visit the [joi.dev](https://joi.dev) Developer Portal for tutorials, documentation, and support ## Useful resources -- [Documentation and API](https://hapi.dev/family/formula/) -- [Version status](https://hapi.dev/resources/status/#formula) (builds, dependencies, node versions, licenses, eol) -- [Changelog](https://hapi.dev/family/formula/changelog/) -- [Project policies](https://hapi.dev/policies/) -- [Free and commercial support options](https://hapi.dev/support/) +- [Documentation and API](https://joi.dev/module/formula/) +- [Version status](https://joi.dev/resources/status/#formula) (builds, dependencies, node versions, licenses, eol) +- [Changelog](https://joi.dev/module/formula/changelog/) +- [Project policies](https://joi.dev/policies/) ## Acknowledgements diff --git a/lib/index.js b/lib/index.js index 871ab1b..4b4d0a2 100755 --- a/lib/index.js +++ b/lib/index.js @@ -13,7 +13,7 @@ const internals = { '[': ']' }, - numberRx: /^(?:[0-9]*\.?[0-9]*){1}$/, + numberRx: /^(?:[0-9]*(\.[0-9]*)?){1}$/, tokenRx: /^[\w\$\#\.\@\:\{\}]+$/, symbol: Symbol('formula'), diff --git a/package.json b/package.json index 218dd6f..4f31447 100755 --- a/package.json +++ b/package.json @@ -1,8 +1,8 @@ { - "name": "@hapi/formula", + "name": "@sideway/formula", "description": "Math and string formula parser.", - "version": "3.0.0", - "repository": "git://github.com/hapijs/formula", + "version": "3.0.1", + "repository": "git://github.com/sideway/formula", "main": "lib/index.js", "types": "lib/index.d.ts", "keywords": [ @@ -16,8 +16,9 @@ ], "dependencies": {}, "devDependencies": { + "typescript": "4.0.x", "@hapi/code": "8.x.x", - "@hapi/lab": "22.x.x" + "@hapi/lab": "24.x.x" }, "scripts": { "test": "lab -a @hapi/code -t 100 -L -Y",