Launch Week Day 5: Introducing Reachability for PHP.Learn More
Socket
Book a DemoSign in
Socket

hyphen

Package Overview
Dependencies
Maintainers
1
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

hyphen - npm Package Compare versions

Comparing version
1.9.1
to
1.10.0
+6
-1
CHANGELOG

@@ -8,2 +8,6 @@ # Changelog

## [Unreleased]
## [1.10.0]
### Changed
- BREAKING CHANGE: Option `html` default value changed to `true`
## [1.9.1] - 2023-11-17

@@ -122,3 +126,4 @@ ### Changed

[Unreleased]: https://github.com/ytiurin/hyphen/compare/v1.9.1...HEAD
[Unreleased]: https://github.com/ytiurin/hyphen/compare/v1.10.0...HEAD
[v1.10.0]: https://github.com/ytiurin/hyphen/compare/v1.9.1...v1.10.0
[v1.9.1]: https://github.com/ytiurin/hyphen/compare/v1.9.0...v1.9.1

@@ -125,0 +130,0 @@ [v1.9.0]: https://github.com/ytiurin/hyphen/compare/v1.8.0...v1.9.0

+1
-1

@@ -241,3 +241,3 @@ /** Text hyphenation in Javascript.

var SETTING_DEFAULT_EXCEPTIONS = [];
var SETTING_DEFAULT_HTML = false;
var SETTING_DEFAULT_HTML = true;
var SETTING_DEFAULT_HYPH_CHAR = "\xAD";

@@ -244,0 +244,0 @@ var SETTING_DEFAULT_MIN_WORD_LENGTH = 5;

{
"name": "hyphen",
"version": "1.9.1",
"version": "1.10.0",
"description": "Text hyphenation in Javascript.",

@@ -20,3 +20,4 @@ "repository": {

},
"homepage": "https://ytiurin.github.io/hyphen"
"homepage": "https://ytiurin.github.io/hyphen",
"browser": "./hyphen.js"
}

@@ -5,2 +5,3 @@ ![Franklin M. Liang's hyphenation algorithm](https://ytiurin.github.io/hyphen/01.png)

[![All Contributors](https://img.shields.io/badge/all_contributors-9-orange.svg?style=flat-square)](#contributors-)
<!-- ALL-CONTRIBUTORS-BADGE:END -->

@@ -27,6 +28,6 @@

HTML tags will automaticly skip hyphenation.
Processor will automaticly skip HTML tags hyphenation.
```javascript
import { hyphenateHTML as hyphenate } from "hyphen/en";
import { hyphenate } from "hyphen/en";

@@ -99,2 +100,3 @@ (async () => {

```
Types definitions are created and maintained by [Krisztián Balla](https://github.com/krisztianb).

@@ -667,4 +669,2 @@

async: true,
// prevent HTML tags from hyphenation
html: true,
// exceptions of hyphenation

@@ -684,4 +684,2 @@ exceptions: ["present", "ta-ble"]

const hyphenate = createHyphenator(patterns, { async: true });
const hyphenateHTML = createHyphenator(patterns, { async: true, html: true });
const hyphenateHTMLSync = createHyphenator(patterns, { html: true });
const hyphenateSync = createHyphenator(patterns);

@@ -697,4 +695,4 @@ ```

```html
<script src="https://cdn.jsdelivr.net/npm/hyphen@1.7.2/hyphen.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/hyphen@1.7.2/patterns/en-us.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/hyphen@1.10.0/patterns/en-us.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/hyphen@1.10.0/hyphen.min.js"></script>
```

@@ -729,3 +727,4 @@

- Option `debug` will be deprecated in further versions
- Option `debug` will be deprecated in further versions;
- Option `html` will be deprecated in further versions.

@@ -771,2 +770,2 @@ ## Contributors ✨

This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!
This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!