@bubblelab/ts-scope-manager 0.1.0 → 0.1.1

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.js +7 -1
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -1,11 +1,17 @@
1
1
  /* eslint-disable @typescript-eslint/no-require-imports, no-undef, @typescript-eslint/no-unused-vars */
2
2
  'use strict';
3
+ const path = require('path');
3
4
  const scope = require('@typescript-eslint/scope-manager');
5
+
4
6
  // Re-export everything from upstream
5
7
  Object.assign(exports, scope);
8
+
6
9
  // Also export resetIds from internal ID module
7
10
  try {
8
- const { resetIds } = require('@typescript-eslint/scope-manager/dist/ID');
11
+ // Find where scope-manager is installed, then load ID.js from there
12
+ const scopeManagerPath = require.resolve('@typescript-eslint/scope-manager');
13
+ const idPath = path.join(path.dirname(scopeManagerPath), 'ID.js');
14
+ const { resetIds } = require(idPath);
9
15
  exports.resetIds = resetIds;
10
16
  } catch (_e) {
11
17
  // noop if upstream layout changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bubblelab/ts-scope-manager",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "private": false,
5
5
  "license": "MIT",
6
6
  "type": "commonjs",