https://github.com/hecom-rn/eslint-plugin-no-date-constructors
https://github.com/hecom-rn/eslint-plugin-no-date-constructors
Last synced: 10 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/hecom-rn/eslint-plugin-no-date-constructors
- Owner: hecom-rn
- Created: 2025-07-21T09:34:42.000Z (12 months ago)
- Default Branch: master
- Last Pushed: 2025-08-08T10:16:36.000Z (11 months ago)
- Last Synced: 2025-08-08T12:18:09.796Z (11 months ago)
- Language: JavaScript
- Size: 1.95 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## eslint-plugin-no-date-constructors
ESLint plugin to disallow problematic date constructors (`new Date()`, `XDate`, `moment()`).
### Usage
In your ESLint configuration (.eslintrc.js):
```
module.exports = {
plugins: ['no-date-constructors'],
rules: {
'no-date-constructors/no-date-constructors': 'error'
}
};
```
### Rules
no-date-constructors/no-date-constructors: disallows new Date(), XDate and moment() constructors
```