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

Improve the rendered files print for each dir by grouping #9735

Closed
4 tasks done
qmhc opened this issue Aug 18, 2022 · 4 comments
Closed
4 tasks done

Improve the rendered files print for each dir by grouping #9735

qmhc opened this issue Aug 18, 2022 · 4 comments

Comments

@qmhc
Copy link
Contributor

qmhc commented Aug 18, 2022

Description

Current prints maybe misaligned when there have two or more output dirs:

178963179-7e27e6e4-7279-40c3-9322-1141561a3f93

image

Suggested solution

For beauty and neatness, I think group each dir print will be better:

lib/
  test.js ...
  other.js ...
  dir/index.js ...

es/
  test.mjs ...
  other.mjs ...
  dir/index.mjs ...

I can create a PR if you approve this idea.

Alternative

No response

Additional context

No response

Validations

@bluwy
Copy link
Member

bluwy commented Aug 18, 2022

Ref: #9111

Actually I just realized something about the output style, because it's not a full path anymore, we cant ctrl/cmd-click the file path to open the file in vscode, for example. I think that would be a feature we won't want to lose.

@qmhc
Copy link
Contributor Author

qmhc commented Aug 18, 2022

How about keeping the full paths:

lib:
  lib/test.js ...
  lib/other.js ...
  lib/dir/index.js ...

es:
  es/test.mjs ...
  es/other.mjs ...
  es/dir/index.mjs ...

The above looks a little weird with indent.

Or we using a title on the top with other color:

lib
lib/test.js ...
lib/other.js ...
lib/dir/index.js ...

es
es/test.mjs ...
es/other.mjs ...
es/dir/index.mjs ...

Or for simple, only using a empty line to divide each group:

lib/test.js ...
lib/other.js ...

es/test.mjs ...
es/other.mjs ...

@bluwy
Copy link
Member

bluwy commented Aug 21, 2022

I don't really have an opinion though as the suggestions are slight variations to the current output 😬 If I have to choose, I'd prefer the current Vite way as the lib/ and es/ etc are dimmed by default, so it should be easy to differentiate in the console. Happy to hear if others have thoughts about this too though.

@bluwy
Copy link
Member

bluwy commented Dec 30, 2022

Vite 4 has updated the logs to be a bit more aligned so I think this is resolved

@bluwy bluwy closed this as completed Dec 30, 2022
@github-actions github-actions bot locked and limited conversation to collaborators Jan 14, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants