1 |
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 |
|
8 | import warning from 'warning';
|
9 |
|
10 |
|
11 |
|
12 |
|
13 |
|
14 | const removedComponent = name => {
|
15 | let didWarnAboutRemoval = false;
|
16 | const warn = () => {
|
17 | if (__DEV__) {
|
18 | warning(didWarnAboutRemoval, `The \`${name}\` component has been removed.`);
|
19 | didWarnAboutRemoval = true;
|
20 | }
|
21 | };
|
22 | return class {
|
23 | constructor() {
|
24 | warn();
|
25 | }
|
26 |
|
27 | static create() {
|
28 | warn();
|
29 | }
|
30 |
|
31 | static init() {
|
32 | warn();
|
33 | }
|
34 |
|
35 | static components = new WeakMap();
|
36 |
|
37 | static options = {};
|
38 | };
|
39 | };
|
40 |
|
41 | export default removedComponent;
|