Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gulp-plugin/eol
Gulp plugin to ensure consistent end of line characters.
https://github.com/gulp-plugin/eol
Last synced: about 2 months ago
JSON representation
Gulp plugin to ensure consistent end of line characters.
- Host: GitHub
- URL: https://github.com/gulp-plugin/eol
- Owner: gulp-plugin
- License: mit
- Created: 2021-07-14T21:12:14.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2023-01-16T11:09:17.000Z (almost 2 years ago)
- Last Synced: 2024-09-23T09:08:07.364Z (3 months ago)
- Language: TypeScript
- Size: 526 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# @gulp-plugin/eol ![npm (custom registry)](https://img.shields.io/npm/v/@gulp-plugin/eol?logo=npm) [![GitHub Package Registry version](https://img.shields.io/github/release/gulp-plugin/eol.svg?label=gpr&logo=github)](https://github.com/gulp-plugin/eol/packages/)
[![Build](https://github.com/gulp-plugin/eol/actions/workflows/node.js.yml/badge.svg)](https://github.com/gulp-plugin/eol/actions/workflows/node.js.yml)
[![Coverage Status](https://coveralls.io/repos/github/gulp-plugin/eol/badge.svg?branch=main)](https://coveralls.io/github/gulp-plugin/eol?branch=main) [![dependencies Status](https://david-dm.org/gulp-plugin/eol/status.svg)](https://david-dm.org/gulp-plugin/eol)Gulp plugin to ensure consistent end of line characters.
## Install
`npm install --save-dev @gulp-plugin/eol`
## Usage
```typescript
const typescript = require('gulp-typescript')
const sourcemaps = require('gulp-sourcemaps')
const eol = require('gulp-plugin/eol')const project = typescript.createProject('tsconfig.json')
function build() {
src('./src/**/*.ts')
.pipe(eol({ eol: '\n' }))
.pipe(sourcemaps.init())
.pipe(project())return compiled.js
.pipe(sourcemaps.write({ sourceRoot: file => path.relative(path.join(file.cwd, file.path), file.base) }))
.pipe(dest('build/'))
}```