Skip to content

Commit 819b926

Browse files
yungstersfacebook-github-bot
authored andcommitted
Animated: Create Experimental Stub
Summary: Creates an experimental stub implementation of `createAnimatedComponent` to be implemented in future commits. Changelog: [Internal] Reviewed By: lunaleaps, kacieb Differential Revision: D28799738 fbshipit-source-id: dc3fbee557db353de6807bd87561f8f372d7cab5
1 parent 8ccc406 commit 819b926

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
/**
2+
* Copyright (c) Facebook, Inc. and its affiliates.
3+
*
4+
* This source code is licensed under the MIT license found in the
5+
* LICENSE file in the root directory of this source tree.
6+
*
7+
* @flow strict-local
8+
* @format
9+
*/
10+
11+
import * as React from 'react';
12+
13+
/**
14+
* Experimental implementation of `createAnimatedComponent` that is intended to
15+
* be compatible with concurrent rendering.
16+
*/
17+
export default function createAnimatedComponent<TProps: {...}, TInstance>(
18+
Component: React.AbstractComponent<TProps, TInstance>,
19+
): React.AbstractComponent<TProps, TInstance> {
20+
return React.forwardRef((props, ref) => {
21+
throw new Error('createAnimatedComponent: Not yet implemented.');
22+
});
23+
}

0 commit comments

Comments
 (0)