Socket
Book a DemoInstallSign in
Socket

@rtcamp/web-components

Package Overview
Dependencies
Maintainers
8
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@rtcamp/web-components

Reusable web components library

1.1.6
latest
Source
npmnpm
Version published
Maintainers
8
Created
Source

Web Components by rtCamp

A collection of reusable, accessible, and customizable web components built with TypeScript, designed to simplify UI development across projects. This package is developed and maintained by the team at rtCamp and is publicly available for anyone to use and contribute.

✨ Why Use This Package?

Modern front-end development often involves repeated creation of the same UI patterns like accordions, sliders, tabs, modals, etc. This package offers a centralized solution:

  • Reusable: Write once, use across multiple projects.
  • 🧩 Modular: Use only the components you need.
  • ⚙️ Framework-Agnostic: Native web components that work with any JavaScript framework.
  • 💡 Developer-Friendly: Built with TypeScript and thoughtfully documented.
  • 🌍 Public & Open Source: Available on npm and GitHub for transparency, collaboration, and contribution.

📦 Installation

npm install @rtcamp/web-components

🚀 Usage

Importing Components

// Import a specific component (e.g., Accordion)
import '@rtcamp/web-components/build/accordion';

// Import global styles
import '@rtcamp/web-components/build/style.css';

// TypeScript usage
import { Accordion } from '@rtcamp/web-components';

You can now use the component as a custom HTML tag:

<rt-accordion></rt-accordion>

🧩 Available Components

We are continually expanding our collection. Current components include:

  • Accordion
  • Slider
  • Tabs
  • Modal
  • Lightbox
  • ...and more

Each component is designed with accessibility and customizability in mind.

📂 Component Structure

Each component is organized with the following conventions:

  • 📄 Each component folder contains a README.md file that explains:
    • Component usage
    • Code examples
    • Component's Attributes, Events and Methods
  • 🧪 A index.html file is included to demonstrate the working demo of the component.
  • 🧱 If a component has multiple elements, those are stored inside an elements/ subfolder for clarity and modularity.
  • 🧩 Each component folder has its own index.ts file, which should define and register custom elements via customElements.define(...).

🧩 Creating a New Component

If you're building a new component, please follow these steps:

  • Export the main component class in the root index file:
    src/index.ts

  • Import your component-specific styles into the main stylesheet:
    src/style.scss

  • Test thoroughly to ensure it works across use cases and devices.

  • Keep styles minimal: The component should only include styles essential for functionality (like layout, visibility toggles, etc.). Avoid opinionated visual styles, as each project may override styles to match its design system.

  • Test thoroughly to ensure the component behaves correctly and is accessible across browsers and screen sizes.

  • Once verified, contact a team member to publish the updated package so it's available for all users.

If in doubt, reach out to our team members actively working on this project for guidance.

🛠️ Local Development

Want to contribute or customize the components?

Getting Started

  • Clone the repository:

    git clone https://github.com/rtCamp/web-components.git
    cd web-components
    
  • Install dependencies:

    npm install
    
  • Start the development server:

    npm run dev
    
  • Build for production:

    npm run build
    
  • Preview any component using a local server. Example:

    php -S localhost:3000
    # Now open http://localhost:3000/src/slider
    

🤝 Contributing

We welcome community contributions!

How to Contribute

  • 🐞 Report issues or suggest features via GitHub Issues.
  • 🛠️ Submit a pull request if you'd like to add or improve a component.

Contribution Guidelines

  • Follow existing coding conventions and folder structure.
  • Include TypeScript types and JSDoc comments.
  • Make sure the component works across browsers and is accessible.
  • Test before submitting a pull request.

📄 License

This project is licensed under the GPL-3.0-or-later. See LICENSE for more details.

💼 BTW, We're Hiring!

Join us at rtCamp, we specialize in providing high performance enterprise WordPress solutions

Keywords

web-components

FAQs

Package last updated on 26 May 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.