Commit Graph
19 Commits
Author SHA1 Message Date
eric scipleandGitHub 656a821a94 ESM migration: Add .js extensions for node16 moduleResolution (#257)
Migrate expressions, workflow-parser, and languageservice packages to use
proper ESM imports with .js extensions that work with node16 moduleResolution.

Changes:
- Update tsconfig.build.json in each package to use module: node16 and
  moduleResolution: node16
- Add .js extensions to all relative import paths (Option B approach)
- Fix yaml internal type imports in workflow-parser by defining local types
- Add skipLibCheck to handle @types/node compatibility issues
- Add TypeScript 5.8.3 override in root package.json
- Add ESM migration plan documentation

The languageserver package is deferred due to test hang issues that need
further investigation.

Related #154 - Upgrade moduleResolution from node to node16 or nodenext
Related #110 - Published ESM code has imports without file extensions
Related #64 - expressions: ERR_MODULE_NOT_FOUND attempting to run example
Related #146 - Can not import @actions/workflow-parser

Test results:
- expressions: 1068 tests passed
- workflow-parser: 292 tests passed
- languageservice: 452 tests passed

* docs: update ESM migration plan with findings

- Update languageserver blocker: vscode-languageserver v8.0.2 lacks ESM
  exports (not a test hang issue)
- Document that Option B (manual .js extensions) was chosen over Option A
  due to ts-jest compatibility issues
- Add workaround for yaml package internal types (LinePos, NodeBase)
- Update migration status table with accurate reason for deferral
- Add skipLibCheck note for @types/node compatibility
2025-12-18 13:35:48 -06:00
eric scipleandGitHub 4181cb3c90 Fix expression completion in multi-line if block scalars (#238)
Fixed the cursor offset calculation for multi-line strings. The original
code unconditionally added +1 for a newline separator, but when the cursor
is on the first content line, there are no lines before it, so adding +1
produced an off-by-one error.

Fixes: vscode-github-actions#81
2025-12-08 09:20:50 -06:00
Christopher Schleiden 4f7d03ed0c Correctly indent completion options 2023-08-04 11:19:42 -07:00
Christopher SchleidenandChristopher Schleiden b82ddcdb42 Update import paths
String replacement from `@github/actions-` to `@actions/`
2023-03-23 09:57:18 -07:00
Josh Gross 8e03b387a2 Cache transformed workflows separately 2023-03-21 15:52:25 -04:00
Josh Gross 9ef34c7e41 Lint the language service package 2023-03-20 13:33:58 -04:00
Josh Gross 8942a05502 Handle undefined templates in workflow template cache 2023-03-17 13:23:43 -04:00
Jacob WallraffandGitHub e3973298fa Merge pull request #172 from github/thyeggman/cache-workflow-results
Cache parsed workflow and template results
2023-03-08 09:18:44 -08:00
Beth Brennan 20170641a5 Pass existingValues consistently 2023-03-07 15:36:47 -05:00
Beth BrennanandGitHub 2683e2e2a8 Merge branch 'main' into elbrenn/secret-complete 2023-03-07 15:23:50 -05:00
Jacob Wallraff 572b193c25 Merge branch 'main' into thyeggman/cache-workflow-results 2023-03-06 15:22:28 -08:00
Jacob Wallraff 6aaeefb9c2 Remove unused code and address feedback 2023-03-06 11:33:28 -08:00
Jacob Wallraff 2fc36cc6a1 Fix imports and format 2023-03-03 12:49:25 -08:00
Jacob Wallraff 5a199d4c52 Rename methods 2023-03-03 12:39:40 -08:00
Jacob Wallraff ffcd06c8c5 Move caching to language service 2023-03-03 12:28:29 -08:00
Laura YuandGitHub 31badfab56 Add trailing colon check for completion (#171) 2023-03-03 11:02:32 -08:00
Jacob Wallraff f2f377c21c Simple caching for parsed workflow and template 2023-03-02 16:43:23 -08:00
Beth Brennan 381d04730e Complete reusable workflow secrets, handle placeholder key 2023-03-01 12:57:36 -05:00
Christopher Schleiden 2a3d63551f Rename folders 2023-02-22 15:52:40 -08:00