# @jikurata/root

> Locates and sets the project root to process.env.root

Latest version **1.0.2** (published 2021-08-31) · ISC license · 0 weekly downloads

## Install

```sh
npm install @jikurata/root
pnpm add @jikurata/root
yarn add @jikurata/root
bun add @jikurata/root
```

## 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 | 1.0.2 |
| Published | 2021-08-31 |
| First published | 2019-01-06 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | jikurata |
| Maintainers | jikurata |
| Keywords | root, path |

## Links

- npm: https://www.npmjs.com/package/@jikurata/root
- npm.io page: https://npm.io/package/@jikurata/root

## Alternatives

- [base64url](https://npm.io/package/base64url.md) — 6.1M weekly downloads
- [get-installed-path](https://npm.io/package/get-installed-path.md) — 502.9K weekly downloads
- [@uppy/url](https://npm.io/package/@uppy/url.md) — 185.8K weekly downloads
- [@d3fc/d3fc-shape](https://npm.io/package/@d3fc/d3fc-shape.md) — 16.2K weekly downloads
- [localizer](https://npm.io/package/localizer.md) — 226 weekly downloads

## Recent versions

- 1.0.2 (latest) — 2021-08-31
- 1.0.1 — 2021-08-28
- 1.0.0 — 2019-01-06

## README

# root v1.0.2
Locate project root path
---
## Install
```
npm install @jikurata/root
```
## Usage
```
// Sets process.env.root = project root path
// Also returns the project root path
const root = require('@jikurata/root');

console.log(root); // /some/project/directory
console.log(process.env.root); // /some/project/directory
```
## Changelog
### v1.0.2
- Fix a conflict with variable declaration for path module
### v1.0.1
- Now uses the path module's sep property to be compatible with different operating systems

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