open-index/open-npm huggingface dataset:
npm package: @fully-studios/cookie-consent
Description: This is a reusable cookie consent library, with components for displaying cookie policy popups and managing cookie consent.
Latest version: 0.5.5

# Cookie-consent

This is a reusable cookie consent library, with components for displaying cookie policy popups and managing cookie consent.

It uses:
 - Vite
 - TypeScript 
 - React
 - [Modular SCSS](https://vitejs.dev/guide/features.html#css-modules)

An example of a reusable component that can be created with this template is a Cookie Consent component that can be used in multiple different projects.

## Prerequisites

- Node.js `>18`
- npm `>9`
- Git

## Getting Started

To use this template, follow these steps:

1. Navigate to the [Cookie-consent](https://gitlab.fullystudios.se/fullystudios/cookie-consent) on GitLab.

2. Click on the "Fork" button at the top right of the page. Pick a name for the library you're making.

3. Clone the forked repository to your local machine

4. Navigate into the cloned repository:

```bash
cd cookie-consent
```

5. Install the dependencies:

```bash
npm install
```

## Customizing the Template

To customize the template for your specific library, you need to change the `name` in the `package.json` file and the `build.lib.name` in the `vite.config.ts` file.

- Open the `package.json` file and change the `name` field to the name of your library.

- Open the `vite.config.ts` file and change the `build.lib.name` field to the name of your library.

## Publishing a New Version

To publish a new version of your library, you need to be logged into an npm account that is part of the @fully-studios organization. Then, follow these steps:

1. Update the version of your library:

```bash
npm version [major|minor|patch]
```

2. Build your library:

```bash
npm run build
```

3. Publish your library:

```bash
npm run publish --access public
```

## Using the library

1. Install the library with npm

```bash
npm i @fully-studios/cookie-consent
```

2. Import and use a component from the library, along with the styles (optional)

```tsx
import { Box } from '@fully-studios/cookie-consent';
// Optional style import, not all libraries will necessarily export these
import '@fully-studios/cookie-consent/style.css';

export default function App() {
  return (
    <Box>
      Something
    </Box>
  );
}

```

## Contributing

Contributions are always welcome! Please feel free to submit a pull request.

## License

This project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details.