Skip to content
This repository has been archived by the owner on Jan 16, 2025. It is now read-only.

Changed output directory structure in 0.2.2 #281

Closed
GNURub opened this issue Jan 24, 2024 · 9 comments · Fixed by #283
Closed

Changed output directory structure in 0.2.2 #281

GNURub opened this issue Jan 24, 2024 · 9 comments · Fixed by #283

Comments

@GNURub
Copy link

GNURub commented Jan 24, 2024

breaking changes

Configurations with "paths" alias generates a diferent output directory:

  • v0.2.0 -> dist/
  • v0.2.2 -> dist/src/
@kdy1
Copy link
Member

kdy1 commented Jan 24, 2024

f87c850 reverts the changes in v0.2.2

@kdy1 kdy1 closed this as completed Jan 24, 2024
@ShogunPanda
Copy link
Contributor

This was then reintroduced in v0.3.0.
Is there a way to get v0.2.x behavior in the latest version?

@kdy1
Copy link
Member

kdy1 commented Jan 24, 2024

You can use v0.2.3, but not inv0.3.x

@ShogunPanda
Copy link
Contributor

Sorry, I'll rephrase: is there any option (or plan to add an option) in v0.3.x to get the same behavior?
If not, would you accept a PR for it?

@kdy1
Copy link
Member

kdy1 commented Jan 25, 2024

I'll accept a PR, but I'm not sure about the name of the option

@ShogunPanda
Copy link
Contributor

Let's choose it together. Out of my mind I'm thinking about the following (in order of preference):

  1. --strip-leading-paths
  2. --resolve-destination-paths
  3. --strip-leading-destination-paths

Do you like any of those? Or do you have any similar suggestion?

@kdy1
Copy link
Member

kdy1 commented Jan 25, 2024

I also prefer the first one

@imranbarbhuiya
Copy link

Hi, is there any way to pass this flag --strip-leading-paths from .swcrc?

@ShogunPanda
Copy link
Contributor

Not at the moment. I plan to implement this in #284.

mrhyde added a commit to 2BAD/ryanair that referenced this issue Feb 7, 2024
mrhyde added a commit to 2BAD/ts-lib-starter that referenced this issue Feb 7, 2024
JosephLeedy added a commit to JosephLeedy/express-magento2-client that referenced this issue Feb 12, 2024
SWC 0.3.0 introduced a breaking change which caused the production build to output to `dist/src` instead of `dist`.

swc-project/cli#281
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging a pull request may close this issue.

4 participants