You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -83,7 +83,7 @@ Using the module/nomodule approach. Have a look at the example in this repositor
83
83
- Create an entry (input) [.js or .mjs or .ts][file for browsers which support ECMAScript modules](https://github.com/mcshaz/esm-date-input-polyfill/blob/master/examples/esm.module.js), which includes a polyfill for dynamic import in browsers which support modules but not dynamic import statements.
84
84
- Have a [seperate entry file for legacy browsers](https://github.com/mcshaz/esm-date-input-polyfill/blob/master/examples/esm.nomodule.js).
85
85
- Modern browsers will only download a tiny file to check for date-input support, and download the appropriate polyfill only if date inputs are not natively supported.
86
-
- Older browsers will download the full executable. See an example [rollup config here](https://github.com/mcshaz/simple-nicu-calc/blob/master/rollup.config.js).
86
+
- Older browsers will download the full executable. See an example [rollup config here](https://github.com/mcshaz/simple-nicu-calcs/blob/master/rollup.config.js).
87
87
- Check if the script has already been run in the [common file](https://github.com/mcshaz/esm-date-input-polyfill/blob/master/examples/esm-page-script.js) that the 2 enty files point to (a problem with Safari 10 respecting `<script type="module" src="...">` but _not_ respecting `<script nomodule src="...">`).
- **Note** the distributable code for this polyfill has been bundled and minified, but intentionally it has not been transpiled by a tool such as babel. This ensures the smallest size file for modern browsers. You will therefore need to make sure you include esm-date-input-polyfill in your babel transpiling and automatic `js` polyfilling process for older browsers. Many bundling config files exclude all node modules with `{ exclude:/node_modules\ }`. Instead, change this to something like:
97
+
- **Note** the distributable code for this polyfill has been bundled and minified, but intentionally it has not been transpiled by a tool such as Babel. This ensures the smallest size file for modern browsers. You will therefore need to make sure you include esm-date-input-polyfill in your transpiling and automatic `js` polyfilling process for older browsers (usually with Babel). Many bundling config files exclude all node modules with `{ exclude:/node_modules/ }`. Instead, change this to something like:
98
98
```js
99
99
rules: [
100
100
{
@@ -107,7 +107,7 @@ export function myScript() {
107
107
```
108
108
109
109
### Script Tag:
110
-
Execute `dateInputPolyfill.polyfillIfRequired()` and if required with an option object with the properties described above. See the example of this workflow [here](https://github.com/mcshaz/esm-date-input-polyfill/blob/master/docs/iife.html).
110
+
Execute `dateInputPolyfill.polyfillIfRequired()` and if required with an option object with the properties described above. See the example of this workflow [in the example html file here](https://github.com/mcshaz/esm-date-input-polyfill/blob/master/docs/iife.html).
111
111
112
112
113
113
## Features
@@ -143,7 +143,7 @@ values in the format `yyyy-MM-dd`.
143
143
`value` *property*.
144
144
145
145
If you don't want that, one potential workaround is to change
146
-
the attribute upon form submission:
146
+
the attribute back to the property value upon form submission:
Given the lifecycle of browsers which do not natively support date-inputs, there no plans to add the features below, however if this project were to have a roadmap:
159
159
- placeholder currently uses english characters e.g. `dd/mm/yyyy`. This should clearly be language specific.
160
160
- separate out language files and dynamically retrieve only the 1 language file required.
161
-
- have a cross inside the right of the input which deletes the selected date. At present to delete the date, the text within the input can be selected and deleted.
161
+
- have a cross inside the right side of the input which deletes the selected date. At present to delete the date, the text within the input can be selected and deleted.
162
162
163
163
## Thanks
164
164
Some words of appreciation for those who have submitted tickets, pull requests,
0 commit comments