Currently, when users navigate to the code tab of the component, only TypeScript (TS) code is available. This poses a challenge for developers working with JavaScript (JS) projects, as they need to manually convert the TS code to JS, which can be time-consuming and error-prone.
Proposed Solution:
To improve the usability and accessibility of the component for a broader range of developers, I propose the following improvements:
1. Separate Tabs for JS and TS:
Introduce two distinct tabs within the code section, one for JavaScript (JS) and the other for TypeScript (TS).
This will allow developers to easily switch between the two languages and use the code that best suits their project needs.
2. Copy Button Functionality:
Add a copy button for both the JS and TS code sections.
This feature will enable developers to copy the code quickly with a single click.
Thank you for the suggestion! Motion-Primitives is intentionally TypeScript focused for specific technical reasons, but I’ll consider providing some guidance for JS users in the documentation.
Description:
Currently, when users navigate to the code tab of the component, only TypeScript (TS) code is available. This poses a challenge for developers working with JavaScript (JS) projects, as they need to manually convert the TS code to JS, which can be time-consuming and error-prone.
Proposed Solution:
To improve the usability and accessibility of the component for a broader range of developers, I propose the following improvements:
1. Separate Tabs for JS and TS:
2. Copy Button Functionality: