Skip to content

Commit ad4a206

Browse files
authored
fix: Types not being exported and autocomplete not working (#284)
* fix: Types not being exported and autocomplete not working * new patch version v9.0.1
1 parent 94bcd3e commit ad4a206

File tree

4 files changed

+14
-8
lines changed

4 files changed

+14
-8
lines changed

index.d.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { IFlagsmith } from './types';
22
declare const flagsmith: IFlagsmith;
33
export default flagsmith;
4+
export * from './types';
45
export declare const createFlagsmithInstance: <
56
F extends string = string,
67
T extends string = string,

lib/flagsmith/package.json

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "flagsmith",
3-
"version": "9.0.0",
3+
"version": "9.0.1",
44
"description": "Feature flagging to support continuous development",
55
"main": "./index.js",
66
"module": "./index.mjs",
@@ -10,22 +10,26 @@
1010
".": {
1111
"import": "./index.mjs",
1212
"require": "./index.js",
13-
"browser": "./index.js"
13+
"browser": "./index.js",
14+
"types": "./index.d.ts"
1415
},
1516
"./isomorphic": {
1617
"import": "./isomorphic.mjs",
1718
"require": "./isomorphic.js",
18-
"browser": "./isomorphic.js"
19+
"browser": "./isomorphic.js",
20+
"types": "./isomorphic.d.ts"
1921
},
2022
"./react": {
2123
"import": "./react.mjs",
2224
"require": "./react.js",
23-
"browser": "./react.js"
25+
"browser": "./react.js",
26+
"types": "./react.d.ts"
2427
},
2528
"./next-middleware": {
2629
"import": "./next-middleware.mjs",
2730
"require": "./next-middleware.js",
28-
"browser": "./next-middleware.js"
31+
"browser": "./next-middleware.js",
32+
"types": "./next-middleware.d.ts"
2933
}
3034
},
3135
"repository": {

lib/react-native-flagsmith/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-native-flagsmith",
3-
"version": "9.0.0",
3+
"version": "9.0.1",
44
"description": "Feature flagging to support continuous development",
55
"main": "./index.js",
66
"repository": {

react.d.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
import React, { FC } from 'react';
2-
import { IFlagsmith, IFlagsmithTrait, IFlagsmithFeature, IState } from '../types';
2+
import { IFlagsmith, IFlagsmithTrait, IFlagsmithFeature, IState, LoadingState } from './types';
3+
export * from './types';
34
export declare const FlagsmithContext: React.Context<IFlagsmith>;
45
export declare type FlagsmithContextType<F extends string = string, T extends string = string> = {
56
flagsmith: IFlagsmith<F, T>;
67
options?: Parameters<IFlagsmith<F, T>['init']>[0];
7-
serverState?: IState<F, T>;
8+
serverState?: IState;
89
children: React.ReactElement[] | React.ReactElement;
910
};
1011
export declare const FlagsmithProvider: FC<FlagsmithContextType>;

0 commit comments

Comments
 (0)