Skip to content

Commit 77d73ec

Browse files
committed
Fix typecheck issues
1 parent 6e98fb1 commit 77d73ec

File tree

10 files changed

+78
-15
lines changed

10 files changed

+78
-15
lines changed

apps/common-app/tsconfig.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"extends": "../../tsconfig.json",
33
"compilerOptions": {
4-
"plugins": [{ "name": "./resolver.js" }],
54
"baseUrl": ".",
65
"paths": {
76
"@/*": ["src/*"]

apps/fabric-example/images.d.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
declare module '*.jpg' {
2+
import type { ImageSourcePropType } from 'react-native';
3+
4+
const value: ImageSourcePropType;
5+
export default value;
6+
}
7+
8+
declare module '*.png' {
9+
import type { ImageSourcePropType } from 'react-native';
10+
11+
const value: ImageSourcePropType;
12+
export default value;
13+
}

apps/fabric-example/tsconfig.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
11
{
22
"extends": "../../tsconfig.json",
3+
"compilerOptions": {
4+
"baseUrl": ".",
5+
"paths": {
6+
"@/*": ["../common-app/src/*"]
7+
}
8+
},
39
"exclude": ["node_modules", "metro.config.js"]
410
}

apps/macos-example/images.d.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
declare module '*.jpg' {
2+
import type { ImageSourcePropType } from 'react-native';
3+
4+
const value: ImageSourcePropType;
5+
export default value;
6+
}
7+
8+
declare module '*.png' {
9+
import type { ImageSourcePropType } from 'react-native';
10+
11+
const value: ImageSourcePropType;
12+
export default value;
13+
}

apps/macos-example/tsconfig.json

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11
{
2-
"extends": "../../tsconfig.json"
3-
// "compilerOptions": {
4-
// "baseUrl": ".",
5-
// "paths": {
6-
// "react-native-reanimated": ["../"],
7-
// "react": ["./node_modules/@types/react"]
8-
// }
9-
// },
10-
// "exclude": []
2+
"extends": "../../tsconfig.json",
3+
"compilerOptions": {
4+
"baseUrl": ".",
5+
"paths": {
6+
"@/*": ["../common-app/src/*"]
7+
// "react": ["./node_modules/@types/react"]
8+
}
9+
}
1110
}

apps/paper-example/images.d.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
declare module '*.jpg' {
2+
import type { ImageSourcePropType } from 'react-native';
3+
4+
const value: ImageSourcePropType;
5+
export default value;
6+
}
7+
8+
declare module '*.png' {
9+
import type { ImageSourcePropType } from 'react-native';
10+
11+
const value: ImageSourcePropType;
12+
export default value;
13+
}

apps/paper-example/tsconfig.json

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
11
{
2-
"extends": "../../tsconfig.json"
2+
"extends": "../../tsconfig.json",
3+
"compilerOptions": {
4+
"baseUrl": ".",
5+
"paths": {
6+
"@/*": ["../common-app/src/*"]
7+
}
8+
}
39
}

apps/web-example/images.d.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
declare module '*.jpg' {
2+
import type { ImageSourcePropType } from 'react-native';
3+
4+
const value: ImageSourcePropType;
5+
export default value;
6+
}
7+
8+
declare module '*.png' {
9+
import type { ImageSourcePropType } from 'react-native';
10+
11+
const value: ImageSourcePropType;
12+
export default value;
13+
}

apps/web-example/tsconfig.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,10 @@
22
"extends": "expo/tsconfig.base",
33
"compilerOptions": {
44
"strict": true,
5+
"baseUrl": "../..",
56
"paths": {
6-
"@/*": ["./*"],
7-
"react-native-reanimated": ["../../packages/react-native-reanimated/src"]
7+
"@/*": ["./apps/common-app/src/*"]
8+
// "react-native-reanimated": ["./packages/react-native-reanimated/src"]
89
}
910
},
1011
"include": ["**/*.ts", "**/*.tsx"]

packages/react-native-reanimated/src/css/component/createAnimatedComponent.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
'use strict';
2-
import { forwardRef } from 'react';
2+
import React from 'react';
33
import type {
44
FunctionComponent,
55
ComponentClass,
@@ -56,7 +56,7 @@ export default function createAnimatedComponent<P extends object>(
5656
}
5757
}
5858

59-
return forwardRef<Component>((props, ref) => {
59+
return React.forwardRef<Component>((props, ref) => {
6060
return (
6161
<AnimatedComponent
6262
{...props}

0 commit comments

Comments
 (0)