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

console.log during build #478

Closed
ovidius72 opened this issue Feb 1, 2020 · 5 comments
Closed

console.log during build #478

ovidius72 opened this issue Feb 1, 2020 · 5 comments
Labels
kind: support Asking for support with something or a specific use case solution: intended behavior This is not a bug and is expected behavior

Comments

@ovidius72
Copy link

ovidius72 commented Feb 1, 2020

Sorry if I'm asking a stupid question but even searching the issues and the documentation i couldn't find a way to console.log when yarn start.
Tried with the --verbose flag but nothing is logged in the terminal. Thanks

@agilgur5
Copy link
Collaborator

agilgur5 commented Feb 2, 2020

Do you mean yarn start in the example/ directory or in the root directory? Because in the root directory that just runs tsdx watch, which is a build process, and as such your source code isn't run there, just built/transpiled.

@ovidius72
Copy link
Author

ovidius72 commented Feb 2, 2020

thank you @agilgur5

I don't see the example directory.
I just installed it with npx tsdx create myProj and then picked up the basic template.
From here I've started adding some stuff in the src/index.ts file just for testing.
yarn start should run the project in development/watch mode if I'm not wrong.

@agilgur5
Copy link
Collaborator

agilgur5 commented Feb 2, 2020

Ok, yes, the basic template does not have an example/ directory.

Seems like you're misunderstanding something -- TSDX is for package/library developers. tsdx build just outputs built files to dist/. tsdx watch just continuously outputs built files to dist/ as you change your code.

TSDX is not running your code, it is building it. There is tsdx test for testing your code though.

@ovidius72
Copy link
Author

I knew mine was a stupid question. I missed the main concept of tsdx. I'm sorry.
Thanks @agilgur5

@agilgur5 agilgur5 added the solution: intended behavior This is not a bug and is expected behavior label Mar 9, 2020
@agilgur5 agilgur5 added the kind: support Asking for support with something or a specific use case label Mar 29, 2020
@agilgur5 agilgur5 changed the title console.log console.log during build Mar 29, 2020
@XavierGeerinck
Copy link

I arrived here after #393

Honestly, I think this service is amazing and enables us to resolve a lot of issues with Typescript in the way we can quickly spin up a Typescript project. Sadly enough I also was going from the understanding that this is mainly for packages and not testing the service :) would be nice if npm run start really starts the project...

Anyways, I understood the use now and will this be looking for other solutions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind: support Asking for support with something or a specific use case solution: intended behavior This is not a bug and is expected behavior
Projects
None yet
Development

No branches or pull requests

3 participants