@ast-grep/napi 0.7.0 → 0.7.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.d.ts +1 -0
  2. package/package.json +9 -9
package/index.d.ts CHANGED
@@ -48,6 +48,7 @@ export class SgNode {
48
48
  follows(m: string): boolean
49
49
  getMatch(m: string): SgNode | null
50
50
  getMultipleMatches(m: string): Array<SgNode>
51
+ getRoot(): SgRoot
51
52
  children(): Array<SgNode>
52
53
  find(matcher: string | number | NapiConfig): SgNode | null
53
54
  findAll(matcher: string | number | NapiConfig): Array<SgNode>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ast-grep/napi",
3
- "version": "0.7.0",
3
+ "version": "0.7.2",
4
4
  "description": "Search and Rewrite code at large scale using precise AST pattern",
5
5
  "main": "index.js",
6
6
  "repository": "https://github.com/ast-grep/ast-grep",
@@ -45,9 +45,9 @@
45
45
  "devDependencies": {
46
46
  "@napi-rs/cli": "2.16.1",
47
47
  "ava": "5.3.1",
48
- "chalk": "5.2.0",
48
+ "chalk": "5.3.0",
49
49
  "ts-node": "10.9.1",
50
- "typescript": "5.1.3"
50
+ "typescript": "5.1.6"
51
51
  },
52
52
  "ava": {
53
53
  "require": [
@@ -64,11 +64,11 @@
64
64
  },
65
65
  "packageManager": "yarn@3.2.3",
66
66
  "optionalDependencies": {
67
- "@ast-grep/napi-win32-x64-msvc": "0.7.0",
68
- "@ast-grep/napi-darwin-x64": "0.7.0",
69
- "@ast-grep/napi-linux-x64-gnu": "0.7.0",
70
- "@ast-grep/napi-win32-ia32-msvc": "0.7.0",
71
- "@ast-grep/napi-darwin-arm64": "0.7.0",
72
- "@ast-grep/napi-win32-arm64-msvc": "0.7.0"
67
+ "@ast-grep/napi-win32-x64-msvc": "0.7.2",
68
+ "@ast-grep/napi-darwin-x64": "0.7.2",
69
+ "@ast-grep/napi-linux-x64-gnu": "0.7.2",
70
+ "@ast-grep/napi-win32-ia32-msvc": "0.7.2",
71
+ "@ast-grep/napi-darwin-arm64": "0.7.2",
72
+ "@ast-grep/napi-win32-arm64-msvc": "0.7.2"
73
73
  }
74
74
  }