Publish your reusable components to npm

This page summarizes the projects mentioned and recommended in the original post on dev.to

Our great sponsors
  • SurveyJS - Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • tsdx

    Zero-config CLI for TypeScript package development

  • Flexbox grids, buttons and padding/margin components are tedious to write from scratch every time you start a new project. They make good candidates for putting in their own npm library. Luckily scaffolding tools like tsdx make this a breeze.

  • storybook

    Storybook is a frontend workshop for building UI components and pages in isolation. Made for UI development, testing, and documentation.

  • import React, { FC, HTMLAttributes, ReactChild } from 'react'; import { Button, ButtonProps } from './Button/Button'; export interface Props extends HTMLAttributes { /** custom content, defaults to 'the snozzberries taste like snozzberries' */ children?: ReactChild; } // Please do not use types off of a default export module or else Storybook Docs will suffer. // see: https://github.com/storybookjs/storybook/issues/9556 /** * A custom Thing component. Neat! */ const Thing: FC = ({ children }) => { return

    {children || `the snozzberries taste like snozzberries`}
    ; }; export { Thing, Button, ButtonProps };

  • SurveyJS

    Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.

    SurveyJS logo
  • tsdx-storybook-test

  • The final code is here if you want to compare your code.

  • React

    The library for web and native user interfaces.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts