Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Jan 28 02:28
    firejune synchronize #1537
  • Jan 28 02:14
    firejune synchronize #1537
  • Jan 28 02:07
    firejune synchronize #1537
  • Jan 22 08:22
    firejune synchronize #1537
  • Jan 22 02:25
    lierdakil closed #1541
  • Jan 21 11:07
    lierdakil synchronize #1541
  • Jan 21 05:46
    firejune edited #1541
  • Jan 21 04:47
    firejune opened #1541
  • Jan 21 02:01
    firejune synchronize #1537
  • Jan 21 01:36
    firejune synchronize #1537
  • Jan 21 00:01
    github-actions[bot] closed #181
  • Jan 20 15:49
    kulikalov opened #1540
  • Jan 20 00:04
    lierdakil closed #1535
  • Jan 20 00:01
    github-actions[bot] closed #231
  • Jan 20 00:01
    github-actions[bot] closed #316
  • Jan 20 00:01
    github-actions[bot] closed #398
  • Jan 20 00:01
    github-actions[bot] closed #780
  • Jan 20 00:01
    github-actions[bot] closed #800
  • Jan 20 00:01
    github-actions[bot] closed #801
  • Jan 19 00:01
    github-actions[bot] closed #803
Thomas Carlsen
@tcarlsen
would be nice with a grammar update :-)
Matt Mischuk
@mattmischuk
@basarat yeah that would be great because I don't need all of the features. :)
@tcarlsen are you going to create that issue? Should I?
Thomas Carlsen
@tcarlsen
Im going to update my package with the latest syntax and grammar. As I say in my README I love the work TypeStrong have done, but the package was to heavy for my taste
maybe splitting up atom-typescript into services (like autocomplete+ did) would be the best way?
but to answer your question,… You go ahead and create the issue :smile:
Thomas Carlsen
@tcarlsen
tcarlsen/language-typescript-grammars-only@e4f0ca7
released
Matt Mischuk
@mattmischuk
wow. released before I can even create an issue. Impressive.
Thomas Carlsen
@tcarlsen
@mattmischuk note that this is for my little language package only copy of atom-typescript.
Matt Mischuk
@mattmischuk
Of course, but it's still nice of you to do that so fast
Sebastian Lenz
@sebastian-lenz
Hi folks, got a little question. I've lowercased the filename of one of my source files, now atom complains that this file is not listed in tsconfig.json but on save it compiles the file with old camel cased name to the output directory. Syncing files does not help, so is there a something like a cache I can additionally clear?
Sebastian Lenz
@sebastian-lenz
Nevermind, was a TypeScript bug, opened an issue there.
Stephen Baynham
@CannibalVox
Hi, what are the best practices for writing a library in typescript that is then consumed by another typescript library? Is it really to manually ///<reference> the output file?
That seems not very robust...?
I'd like to use import from, but it seems like that's not compatible with the dts files produced by the typescript compiler
I'd have to manually edit those dts files I guess?
Stephen Baynham
@CannibalVox
Honestly I'm not particularly clear on how to do libraries generally, given the recommendation to not use --out.
Basarat Ali Syed
@basarat

Hi, what are the best practices for writing a library in typescript that is then consumed by another typescript library? Is it really to manually ///<reference> the output file?

@CannibalVox No just use commonjs with declaration true. A quickstart : http://basarat.gitbooks.io/typescript/content/docs/node/nodejs.html

Stephen Baynham
@CannibalVox
@basarat Error message says it's not a module, because the DTS files being produced by typescript aren't really ambient modules it seems?
Stephen Baynham
@CannibalVox
I guess I can have gulp place an ambient declaration before & after the DTS output, is that the best way? Seems crazy that I have to do a full gulp build, deploy, update to have two projects open in Atom, one of which relies on the other.
Also is there any way to not compile to a single file but have the compiled output not be mixed in with the source?
Basarat Ali Syed
@basarat

because the DTS files being produced by typescript aren't really ambient modules it seems?

They should be. Should have stuff like export var at the root level of the file .... that makes them an ambient export module

Also is there any way to not compile to a single file but have the compiled output not be mixed in with the source?

You can use outDir. But I recommend against that as it becomes fairly weird ... fairly quickly

Stephen Baynham
@CannibalVox
All that's at the root level is declare namespace
because the root of my source files looks like this:
namespace TechnicCommon {
export class VersionedResource extends WebResource {
is that not correct?
Basarat Ali Syed
@basarat

is that not correct?

No. export needs to be at the root level . (ref)

Stephen Baynham
@CannibalVox
Basarat Ali Syed
@basarat
@CannibalVox at the bottom of that page For most projects we recommend using external modules and using namespace for quick demos and porting old JavaScript code.
Stephen Baynham
@CannibalVox
Okay, I have two classes that are in the same exported module, one inherits from the other and both need to be available to consumers. I've tried marking just the module for export, but in that case the class doesn't appear in the DTS file. If I mark the class for export, though, it's not marked as export in the DTS file. This seems like it's probably fine, but when compiling the child class it gives me an "all export or all local" error. This happens even when I'm importing directly from the TS file, though.
Basarat Ali Syed
@basarat
@CannibalVox parent : http://pastebin.com/9wEkrWBh child : http://pastebin.com/881JdDXj :rose:
Note: using namespaces with external modules is generally redundant
also ES6 import should not contain the extension .ts in child
Stephen Baynham
@CannibalVox
Yeah, sorry, I wasn't using it before I just wanted to see if it was picking up the DTS instead somehow
Okay, thanks.
I understand how this should work now, thanks a ton!
Basarat Ali Syed
@basarat
no worries :rose:
Gerasimos (Makis) Maropoulos
@removed~kataras
basarat I have a problem !
look at DefinitelyTyped room :/
Basarat Ali Syed
@basarat
^ Done :rose:
Jari Pennanen
@Ciantic
Hello! Is it possible to get node auto completion without TSD files? I'm thinking about writing my one-off-script in TS and node.
I started in Python, but even though this ends up being like ~200 lines at max, it would be nice to have auto-completion :)
Basarat Ali Syed
@basarat

Is it possible to get node auto completion without TSD files

@Ciantic Not easily. Best solution seems adding integration with TSD to download files for you on demand. PS: I'm heading home right now :rose:

Jari Pennanen
@Ciantic
yeah, I think the tsd is not that cumbersome, for some reason I just wanted to keep all the details of the script in single file, but I think it's a useless requirement
Jari Pennanen
@Ciantic
well :D I think I'll go with Python: tsd install csv >> zero results
I always forget, everybody is not using TS in npm