TypeStrong / atom-typescript

The only TypeScript package you will ever need
https://atom.io/packages/atom-typescript
MIT License
1.13k stars 205 forks source link

activating via init script not working? #1538

Closed chrisdrackett closed 4 years ago

chrisdrackett commented 4 years ago

I'm not sure if something changed recently, but I'm trying to use this package with language-babel and the init screen no longer seems to be working. I know atom also recently updated, but wanted to check here as well.

do (grammarPackageImUsing = "language-babel") ->
  atom.packages.onDidTriggerActivationHook "#{grammarPackageImUsing}:grammar-used", ->
    atom.packages.triggerActivationHook 'language-typescript:grammar-used'
lierdakil commented 4 years ago

Apparently, Atom now uses Javascript for its init script (well, at least that's the case for me on Atom 1.41)? Anyway, the equivalent JS code is like this:

{
  const grammarPackageImUsing = "language-babel";
  atom.packages.onDidTriggerActivationHook(
    `${grammarPackageImUsing}:grammar-used`,
    () =>
      atom.packages.triggerActivationHook("language-typescript:grammar-used")
  );
}
lierdakil commented 4 years ago

Ah, right, 1.43 is out already. Let me update and get back to you

lierdakil commented 4 years ago

The code above works on 1.43 also.