Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/remove finddomnode #308

Open
wants to merge 17 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 15 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .babelrc
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"@babel/preset-react"
],
"plugins": [
["@babel/plugin-proposal-class-properties", { "loose": true }],
["@babel/plugin-proposal-class-properties", { "loose": true }]
],
"env": {
"test": {
Expand Down
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ node_modules
lib
dist
npm-debug.log
browserStack.json
browserStack.json
Session.vim
24 changes: 12 additions & 12 deletions .size-snapshot.json
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
{
"dist/react-input-mask.js": {
"bundled": 79669,
"minified": 26008,
"gzipped": 8342
"bundled": 72731,
"minified": 23443,
"gzipped": 7886
},
"lib/react-input-mask.development.js": {
"bundled": 30278,
"minified": 12895,
"gzipped": 4267
"bundled": 29131,
"minified": 12358,
"gzipped": 4109
},
"dist/react-input-mask.min.js": {
"bundled": 44160,
"minified": 15279,
"gzipped": 5298
"bundled": 30580,
"minified": 10544,
"gzipped": 3782
},
"lib/react-input-mask.production.min.js": {
"bundled": 28947,
"minified": 11818,
"gzipped": 3931
"bundled": 28000,
"minified": 11281,
"gzipped": 3783
}
}
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -188,5 +188,11 @@ cy.get("input")
.should("have.value", "12/34/5___");
````

# Building

Running `npm install` runs `lint`, `test`, `clean` and `build` scripts too.

Set the `CHROME_BIN` environment variable which is the path to the Chrome binary to prevent karma errors in `npm run test`.

# Thanks
Thanks to [BrowserStack](https://www.browserstack.com/) for the help with testing on real devices
4 changes: 2 additions & 2 deletions dev/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ import InputMask from "../src";
function Input() {
const [value, setValue] = useState("");

function onChange(event) {
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fix eslint error

const onChange = event => {
setValue(event.target.value);
}
};

return <InputMask mask="99/99/9999" value={value} onChange={onChange} />;
}
Expand Down
4 changes: 2 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/* eslint-disable import/no-unresolved */

if (process.env.NODE_ENV === "production") {
module.exports = require("./lib/react-input-mask.production.min.js");
module.exports = require("./lib/react-input-mask.production.min");
} else {
module.exports = require("./lib/react-input-mask.development.js");
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fix eslint errors

module.exports = require("./lib/react-input-mask.development");
}
Loading