Socket
Socket
Sign inDemoInstall

unist-util-stringify-position

Package Overview
Dependencies
1
Maintainers
2
Versions
13
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 3.0.3 to 4.0.0

22

lib/index.d.ts

@@ -11,6 +11,2 @@ /**

*
* @typedef PositionLike
* @property {PointLike | null | undefined} [start]
* @property {PointLike | null | undefined} [end]
*
* @typedef PointLike

@@ -20,2 +16,6 @@ * @property {number | null | undefined} [line]

* @property {number | null | undefined} [offset]
*
* @typedef PositionLike
* @property {PointLike | null | undefined} [start]
* @property {PointLike | null | undefined} [end]
*/

@@ -26,3 +26,3 @@ /**

*
* @param {Node | NodeLike | Position | PositionLike | Point | PointLike | null | undefined} [value]
* @param {Node | NodeLike | Point | PointLike | Position | PositionLike | null | undefined} [value]
* Node, position, or point.

@@ -42,6 +42,6 @@ * @returns {string}

| NodeLike
| Point
| PointLike
| Position
| PositionLike
| Point
| PointLike
| null

@@ -57,6 +57,2 @@ | undefined

}
export type PositionLike = {
start?: PointLike | null | undefined
end?: PointLike | null | undefined
}
export type PointLike = {

@@ -67,1 +63,5 @@ line?: number | null | undefined

}
export type PositionLike = {
start?: PointLike | null | undefined
end?: PointLike | null | undefined
}

@@ -12,6 +12,2 @@ /**

*
* @typedef PositionLike
* @property {PointLike | null | undefined} [start]
* @property {PointLike | null | undefined} [end]
*
* @typedef PointLike

@@ -21,2 +17,6 @@ * @property {number | null | undefined} [line]

* @property {number | null | undefined} [offset]
*
* @typedef PositionLike
* @property {PointLike | null | undefined} [start]
* @property {PointLike | null | undefined} [end]
*/

@@ -28,3 +28,3 @@

*
* @param {Node | NodeLike | Position | PositionLike | Point | PointLike | null | undefined} [value]
* @param {Node | NodeLike | Point | PointLike | Position | PositionLike | null | undefined} [value]
* Node, position, or point.

@@ -31,0 +31,0 @@ * @returns {string}

{
"name": "unist-util-stringify-position",
"version": "3.0.3",
"version": "4.0.0",
"description": "unist utility to serialize a node, position, or point as a human readable location",

@@ -30,4 +30,3 @@ "license": "MIT",

"type": "module",
"main": "index.js",
"types": "index.d.ts",
"exports": "./index.js",
"files": [

@@ -39,8 +38,8 @@ "lib/",

"dependencies": {
"@types/unist": "^2.0.0"
"@types/unist": "^3.0.0"
},
"devDependencies": {
"@types/mdast": "^3.0.0",
"@types/node": "^18.0.0",
"c8": "^7.0.0",
"@types/mdast": "^4.0.0",
"@types/node": "^20.0.0",
"c8": "^8.0.0",
"prettier": "^2.0.0",

@@ -50,4 +49,4 @@ "remark-cli": "^11.0.0",

"type-coverage": "^2.0.0",
"typescript": "^4.0.0",
"xo": "^0.53.0"
"typescript": "^5.0.0",
"xo": "^0.54.0"
},

@@ -59,19 +58,16 @@ "scripts": {

"test-api": "node --conditions development test.js",
"test-coverage": "c8 --check-coverage --100 --reporter lcov npm run test-api",
"test-coverage": "c8 --100 --reporter lcov npm run test-api",
"test": "npm run build && npm run format && npm run test-coverage"
},
"prettier": {
"tabWidth": 2,
"useTabs": false,
"singleQuote": true,
"bracketSpacing": false,
"semi": false,
"trailingComma": "none"
"singleQuote": true,
"tabWidth": 2,
"trailingComma": "none",
"useTabs": false
},
"xo": {
"prettier": true
},
"remarkConfig": {
"plugins": [
"preset-wooorm"
"remark-preset-wooorm"
]

@@ -82,4 +78,8 @@ },

"detail": true,
"ignoreCatch": true,
"strict": true
},
"xo": {
"prettier": true
}
}

@@ -42,3 +42,3 @@ # unist-util-stringify-position

This package is [ESM only][esm].
In Node.js (version 14.14+ and 16.0+), install with [npm][]:
In Node.js (version 16+), install with [npm][]:

@@ -52,3 +52,3 @@ ```sh

```js
import {stringifyPosition} from 'https://esm.sh/unist-util-stringify-position@3'
import {stringifyPosition} from 'https://esm.sh/unist-util-stringify-position@4'
```

@@ -60,3 +60,3 @@

<script type="module">
import {stringifyPosition} from 'https://esm.sh/unist-util-stringify-position@3?bundle'
import {stringifyPosition} from 'https://esm.sh/unist-util-stringify-position@4?bundle'
</script>

@@ -118,7 +118,10 @@ ```

Projects maintained by the unified collective are compatible with all maintained
Projects maintained by the unified collective are compatible with maintained
versions of Node.js.
As of now, that is Node.js 14.14+ and 16.0+.
Our projects sometimes work with older versions, but this is not guaranteed.
When we cut a new major release, we drop support for unmaintained versions of
Node.
This means we try to keep the current release line,
`unist-util-stringify-position@^4`, compatible with Node.js 16.
## Security

@@ -167,5 +170,5 @@

[size-badge]: https://img.shields.io/bundlephobia/minzip/unist-util-stringify-position.svg
[size-badge]: https://img.shields.io/badge/dynamic/json?label=minzipped%20size&query=$.size.compressedSize&url=https://deno.bundlejs.com/?q=unist-util-stringify-position
[size]: https://bundlephobia.com/result?p=unist-util-stringify-position
[size]: https://bundlejs.com/?q=unist-util-stringify-position

@@ -194,7 +197,7 @@ [sponsors-badge]: https://opencollective.com/unified/sponsors/badge.svg

[contributing]: https://github.com/syntax-tree/.github/blob/HEAD/contributing.md
[contributing]: https://github.com/syntax-tree/.github/blob/main/contributing.md
[support]: https://github.com/syntax-tree/.github/blob/HEAD/support.md
[support]: https://github.com/syntax-tree/.github/blob/main/support.md
[coc]: https://github.com/syntax-tree/.github/blob/HEAD/code-of-conduct.md
[coc]: https://github.com/syntax-tree/.github/blob/main/code-of-conduct.md

@@ -201,0 +204,0 @@ [unist]: https://github.com/syntax-tree/unist

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc