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

Clarification #9

Closed
pitosalas opened this issue Jul 10, 2015 · 4 comments
Closed

Clarification #9

pitosalas opened this issue Jul 10, 2015 · 4 comments
Labels

Comments

@pitosalas
Copy link

"If you now create a new file bar.ts in the same project, you will be allowed by the TypeScript type system to use the variable foo as if it was available globally:"

From the section on modules. What does it mean to say "in the same project"? Under the same tsconfig.json? So a project is parsed and reports named conflicts / allows sharing across files? Which implies a --out? Which in turn is actively discouraged?

It might be good to clarify that sentence along those lines. Thanks.

@basarat
Copy link
Owner

basarat commented Jul 10, 2015

Under the same tsconfig.json

Yes.

So a project is parsed and reports named conflicts / allows sharing across files

yes

which implies a --out

No. Not unless you explicilty rely on --out. The global namespace is still useful for external libraries (e.g. jquery definitions).

Which in turn is actively discouraged

Yes.

It might be good to clarify that sentence along those lines.

I'll do that 🌹

@basarat
Copy link
Owner

basarat commented Jul 10, 2015

I've moved tsconfig.json docs to the top so that in the same project is clear.

@pitosalas
Copy link
Author

Also, though, I think the term “project” or “in the same project” is never really defined. 

— Pito

On July 10, 2015 at 7:00:13 PM, Basarat Ali Syed (notifications@github.com) wrote:

I've moved tsconfig.json docs to the top so that in the same project is clear.


Reply to this email directly or view it on GitHub.

@basarat
Copy link
Owner

basarat commented Jul 10, 2015

Also, though, I think the term “project” or “in the same project” is never really defined.

I realized that and did that in the same push referenced above. Screenshot:

image

Thanks for your feedback 🌹

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants