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

CodeSandbox CI builds don't include JS #586

Closed
raunofreiberg opened this issue May 13, 2020 · 2 comments · Fixed by #588
Closed

CodeSandbox CI builds don't include JS #586

raunofreiberg opened this issue May 13, 2020 · 2 comments · Fixed by #588

Comments

@raunofreiberg
Copy link
Contributor

raunofreiberg commented May 13, 2020

This is not related to the components themselves, but rather the Codesandbox PR deployments.

Take a look at https://codesandbox.io/s/hardcore-hertz-fu7d8. Notice that there's an error when importing components from @reach/tabs (this applies to all packages).

On further inspection, downloading the package (https://pkg.csb.dev/reach/reach-ui/commit/61bcce10/@reach/tabs") via Codesandbox and opening it reveals that it does not include any JS:

➜  Downloads ls package
README.md    package.json styles.css

I am not sure what the problem here is but it's something we should definitely fix.

@raunofreiberg
Copy link
Contributor Author

raunofreiberg commented May 13, 2020

To be continued...

It seems like usage of Array.flatMap is causing the error here:

.flatMap(file => glob(file));

Inspecting the CI build of Codesandbox throws an error about it for every package:

@reach/utils: (node:224) UnhandledPromiseRejectionWarning: TypeError: _b.apply(...).flatMap is not a function
    at /tmp/01efb6d3/scripts/utils.ts:70:6

@raunofreiberg
Copy link
Contributor Author

Apparently, for now, there is no way to change the Node version (10.18.1) inside the CI container:
https://twitter.com/codesandbox/status/1262349909216370688

Let's just check for flatMap instead and fall back to an alternative implementation.

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

Successfully merging a pull request may close this issue.

1 participant