# react-codepen

> A react component to embed pens from codepen.io

Latest version **0.1.0** (published 2015-08-31) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-codepen
pnpm add react-codepen
yarn add react-codepen
bun add react-codepen
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.0 |
| Published | 2015-08-31 |
| First published | 2015-08-31 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >= 0.10.0 |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 27 |
| Author | Jason Bellamy |
| Maintainers | jasonbellamy |
| Keywords | react, react-component, codepen, editor, embed |

## Links

- npm: https://www.npmjs.com/package/react-codepen
- Repository: https://github.com/jasonbellamy/react-codepen
- Issues: https://github.com/jasonbellamy/react-codepen/issues
- npm.io page: https://npm.io/package/react-codepen

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 0.1.0 (latest) — 2015-08-31

## README

# React &lt;Codepen&gt;

> A react component to embed pens from [codepen.io](http://codepen.io)


## Getting Started

- Install with [NPM](https://www.npmjs.org/) - `npm install --save react-codepen`


## Usage

```javascript
var React   = require('react');
var Codepen = require('react-codepen');

var Component = React.createClass({
  render: function () {
    return (
      <Codepen user="jasonbellamy" hash="XmWNEY"></Codepen>
    );
  }
});
```


## Options


Property | Type     | Argument     | Values                   | Default   | Description
---------|----------|--------------|--------------------------|-----------|------------
user     | `string` | `<required>` |                          | `null`    | [codepen.io](http://codepen.io) username.
hash     | `string` | `<required>` |                          | `null`    | the hash id of the pen to display.
height   | `string` | `<optional>` | `px, %`                  | `250px`   | the height of the pen.
width    | `string` | `<optional>` | `px, %`                  | `100%`    | the width of the pen.
tab      | `string` | `<optional>` | `css, html, js, result`  | `result`  | the default tab that should be displayed.
theme    | `string` | `<optional>` |                          | `default` | the theme the pen should use.


## Developing

[react-codepen](https://github.com/jasonbellamy/react-codepen) is built using **ES6**. Run the following task to compile the `src/` into `dist/`.

```bash
npm run build
```


## Contributing
In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality.


## License
Copyright (c) 2015 [Jason Bellamy ](http://jasonbellamy.com)  
Licensed under the MIT license.

---
_Source: https://npm.io/package/react-codepen · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
