Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The program object in the strict language service is no longer undefined #74

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Expand Up @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project
adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [2.4.2] - 2024-04-09

### Fixed

- The strict language service program object is no longer undefined

## [2.4.1] - 2024-04-09

### Fixed
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
@@ -1,6 +1,6 @@
{
"name": "typescript-strict-plugin",
"version": "2.4.1",
"version": "2.4.2",
"description": "Typescript tools that help with migration to the strict mode",
"author": "Allegro",
"contributors": [
Expand Down
5 changes: 2 additions & 3 deletions src/plugin/index.ts
Expand Up @@ -7,13 +7,12 @@ import {
} from './utils';
import * as ts from 'typescript/lib/tsserverlibrary';

const init: ts.server.PluginModuleFactory = ({ typescript }) => {
const init: ts.server.PluginModuleFactory = () => {
function create(info: PluginInfo) {
const proxy = setupLanguageServiceProxy(info);

const strictLanguageServiceHost = setupStrictLanguageServiceHostProxy(info);
const strictLanguageService = typescript.createLanguageService(strictLanguageServiceHost);
strictLanguageService.getProgram();
const strictLanguageService = ts.createLanguageService(strictLanguageServiceHost);

log(info, 'Plugin initialized');

Expand Down