# ref-move

> ----

Latest version **1.0.4** (published 2016-05-13) · ISC license · 0 weekly downloads

## Install

```sh
npm install ref-move
pnpm add ref-move
yarn add ref-move
bun add ref-move
```

## 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.4 |
| Published | 2016-05-13 |
| First published | 2016-05-06 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Maintainers | guowei121493 |

## Links

- npm: https://www.npmjs.com/package/ref-move
- Repository: https://github.com/carlos121493/ref-move
- Homepage: https://github.com/carlos121493/ref-move#readme
- Issues: https://github.com/carlos121493/ref-move/issues
- npm.io page: https://npm.io/package/ref-move

## Dependencies (1)

- [match-require](https://npm.io/package/match-require.md) ^1.1.1

## Recent versions

- 1.0.4 (latest) — 2016-05-13
- 1.0.3 — 2016-05-13
- 1.0.2 — 2016-05-13
- 1.0.1 — 2016-05-13
- 1.0.0 — 2016-05-08
- 0.1.0 — 2016-05-06

## README

## ref-move

----

a tool for let javascript files reference relative path to absolute;

```
import '../test' => import '/<your root>/<project path>/test'
import {test} from '../test' => import test from '/<your root>/<project path>/test'
const test = require('../test') => const test = require('/<your root>/<project path>/test)
```

[![Coverage Status](https://coveralls.io/repos/github/carlos121493/ref-move/badge.svg?branch=master)](https://coveralls.io/github/carlos121493/ref-move?branch=master)
[![node](https://img.shields.io/node/v/gh-badges.svg?maxAge=2592000)](https://nodejs.org/download/)
[![npm](https://img.shields.io/npm/v/npm.svg?maxAge=2592000)](npm-url)
[![npm](https://img.shields.io/npm/dt/express.svg?maxAge=2592000)](npm-url)

---

[![NPM](https://nodei.co/npm-dl/https://nodei.co/npm/moment.png)](npm-url)

[npm-url]: https://www.npmjs.com/package/ref-move

## usage

---

- just pass the file path convert

```
var refMove = require('ref-move');
var path = require('path')

refMove.replaceRelative(path.join(cwd, 'tests/default-string.js'));

```

- pass the file path and convert sperate

```
var refMove = require('ref-move');
var path = require('path')
var fs = require('fs');
var content = fs.readFileSync('./package.json');

refMove.replaceRelative(path.join(cwd, 'tests/), content);

```

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