You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to use alps-react library in my react project with typescript.
My first problem is missing of TypeScript declaration file (.d.ts file).
> npm i --save @types/alps-react npm ERR! code E404 npm ERR! 404 Not Found - GET https://registry.npmjs.org/@types%2falps-react - Not found npm ERR! 404 npm ERR! 404 '@types/alps-react@*' is not in this registry.
Next problem is that not all components are exported, so the example in the readme is not working:
Failed to compile.
Attempted import error: 'Body' is not exported from 'alps-react' (imported as 'Body').
ERROR in ./src/App.tsx 48:39-43
export 'Body' (imported as 'Body') was not found in 'alps-react' (possible exports: AlpsContextProvider, DrawerContextProvider, LinkContextProvider, breakpoints, breakpointsWidths, getExternalAssets)
ERROR in ./src/App.tsx 51:41-44
export 'Div' (imported as 'Div') was not found in 'alps-react' (possible exports: AlpsContextProvider, DrawerContextProvider, LinkContextProvider, breakpoints, breakpointsWidths, getExternalAssets)
ERROR in ./src/App.tsx 54:44-50
export 'Button' (imported as 'Button') was not found in 'alps-react' (possible exports: AlpsContextProvider, DrawerContextProvider, LinkContextProvider, breakpoints, breakpointsWidths, getExternalAssets)
ERROR in ./src/App.tsx 60:43-53
export 'MediaBlock' (imported as 'MediaBlock') was not found in 'alps-react' (possible exports: AlpsContextProvider, DrawerContextProvider, LinkContextProvider, breakpoints, breakpointsWidths, getExternalAssets)
ERROR in ./src/App.tsx 82:43-53
export 'Blockquote' (imported as 'Blockquote') was not found in 'alps-react' (possible exports: AlpsContextProvider, DrawerContextProvider, LinkContextProvider, breakpoints, breakpointsWidths, getExternalAssets)
The text was updated successfully, but these errors were encountered:
eli-sda
changed the title
Need type definition file. Not all components are exported
I need a declaration file. Not all components are exported
Sep 15, 2023
I'm trying to use alps-react library in my react project with typescript.
> npm i --save @types/alps-react npm ERR! code E404 npm ERR! 404 Not Found - GET https://registry.npmjs.org/@types%2falps-react - Not found npm ERR! 404 npm ERR! 404 '@types/alps-react@*' is not in this registry.
The text was updated successfully, but these errors were encountered: