# p4-require

> Just include it on your page:

Latest version **2.0.0** (published 2017-09-03) · 0 weekly downloads

## Install

```sh
npm install p4-require
pnpm add p4-require
yarn add p4-require
bun add p4-require
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.0.0 |
| Published | 2017-09-03 |
| First published | 2016-12-21 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Maintainers | streamich |

## Links

- npm: https://www.npmjs.com/package/p4-require
- npm.io page: https://npm.io/package/p4-require

## Recent versions

- 2.0.0 (latest) — 2017-09-03
- 0.0.7 — 2016-12-21
- 0.0.6 — 2016-12-21
- 0.0.5 — 2016-12-21
- 0.0.4 — 2016-12-21
- 0.0.3 — 2016-12-21
- 0.0.2 — 2016-12-21
- 0.0.1 — 2016-12-21

## README

# `require` function for browser

Just include it on your page:

```html
<script src="https://unpkg.com/p4-require@latest></script>
```

And you get a `require` function which you can use like you would in Node.js, you
just need to specify the exact versions of the packeges you want to use inline
using `@x.x.x` syntax:

```js
var Backbone = require('backbone@1.3.3');

var User = Backbone.Model.extend({});
var user = new User({name: 'Ivan'});

console.log('User name is ' + user.get('name'));
```


See [JsFiddel example](https://jsfiddle.net/6a96vLoj/5/).

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