https://github.com/rafaelrinaldi/curlyq
Convert straight quotes to smart quotes
https://github.com/rafaelrinaldi/curlyq
curly quote quotes smart straight
Last synced: 11 months ago
JSON representation
Convert straight quotes to smart quotes
- Host: GitHub
- URL: https://github.com/rafaelrinaldi/curlyq
- Owner: rafaelrinaldi
- License: mit
- Created: 2020-05-10T18:56:43.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2020-05-10T21:33:14.000Z (about 6 years ago)
- Last Synced: 2025-07-29T10:26:37.332Z (11 months ago)
- Topics: curly, quote, quotes, smart, straight
- Language: JavaScript
- Homepage:
- Size: 112 KB
- Stars: 3
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# curlyq [](https://github.com/rafaelrinaldi/curlyq/actions)
>Convert straight quotes to smart quotes
## Install
```sh
npm i @rafaelrinaldi/curlyq
```
## Usage
### CLI
```sh
$ curlyq
Usage: curlyq [-] [STRING] [FILE]
Convert straight quotes to smart quotes
Example:
$ curlyq \""That's a 'magic' shoe.\""
“That’s a ‘magic’ shoe.”
Via stdin:
$ echo \""That's a 'magic' shoe.\"" | curlyq
“That’s a ‘magic’ shoe.”
Via file:
$ echo \""That's a 'magic' shoe.\"" > file.txt
$ curlyq file.txt
“That’s a ‘magic’ shoe.”
Options:
-v --version Display current program version
-h --help Display help and usage details
```
### Node.js
```ts
const { curlyq } = require('@rafaelrinaldi/curlyq')
curlyq(`"That's a 'magic shoe."`) //=> “That’s a ‘magic’ shoe.”
```
### React Component
You must include React as a dependency first:
```sh
npm i react -S
```
```tsx
import React, { FunctionComponent } from 'react'
import { CurlyQ } from '@rafaelrinaldi/curlyq'
export const App: FunctionComponent = () => (
"That's a 'magic' shoe."
also
works
with
"deeply" nested nodes
)
```
## License
MIT © [Rafael Rinaldi](https://rinaldi.io)