Skip to content
This repository was archived by the owner on Oct 7, 2020. It is now read-only.

Commit 045b105

Browse files
committed
added deprecation info
1 parent 306a8e6 commit 045b105

File tree

1 file changed

+29
-1
lines changed

1 file changed

+29
-1
lines changed

README.md

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,32 @@
1-
document-register-element
1+
# Deprecated
2+
3+
This polyfill has served the Web well in the last 6 years, but it's time to use the *V1* only polyfill, which includes custom elements builtin extends like this one did before.
4+
5+
Such polyfill is in *npm* as [@ungap/custom-elements](https://github.com/ungap/custom-elements#readme) and it does all features detections for every browser without any need to worry about anything.
6+
7+
```html
8+
<script src="//unpkg.com/@ungap/custom-elements"></script>
9+
<script>
10+
// alternatively, if bundlers are around
11+
import '@ungap/custom-elements';
12+
// or
13+
require('@ungap/custom-elements');
14+
</script>
15+
```
16+
17+
However, if all you need is custom elements without builtin extends, a module also used by `@ungap/custom-elements` , [@webreflection/custom-elements-no-builtin](https://github.com/WebReflection/custom-elements-no-builtin#readme) is your stop.
18+
19+
20+
```html
21+
<script>
22+
if(!self.customElements)
23+
document.write('<script src="//unpkg.com/@webreflection/custom-elements-no-builtin"><\x2fscript>');
24+
</script>
25+
```
26+
27+
Alternatively, if it's a **ponyfill** hat you are after, see [@webreflection/custom-elements](https://github.com/WebReflection/custom-elements#how-to-polyfill) instructions, as this module is already exported as *ponyfill*.
28+
29+
- - -
230

331
[![build status](https://travis-ci.org/WebReflection/document-register-element.svg)](https://travis-ci.org/WebReflection/document-register-element) [![donate](https://img.shields.io/badge/$-donate-ff69b4.svg?maxAge=2592000&style=flat)](https://github.com/WebReflection/donate) [![Backers on Open Collective](https://opencollective.com/document-register-element/backers/badge.svg)](#backers) [![Sponsors on Open Collective](https://opencollective.com/document-register-element/sponsors/badge.svg)](#sponsors)
432
=========================

0 commit comments

Comments
 (0)