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

Move file system operations to separate module #510

Merged
merged 1 commit into from Jan 22, 2020
Merged

Conversation

@tomayac
Copy link
Collaborator

tomayac commented Jan 22, 2020

  • Instead of doing the feature detection inline, this is now outsourced to browser-nativefs, which makes the code a lot easier to read. This new library dynamically imports only the relevant code path (legacy or Native File System API), albeit this advantage is down-transpiled at the moment.

  • Add two missing fields to package.json.

@now

This comment has been minimized.

Copy link

now bot commented Jan 22, 2020

This pull request is being automatically deployed with ZEIT Now (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://zeit.co/vjeux/excalidraw/8476dp23e
Preview: https://excalidraw-git-browser-nativefs.vjeux.now.sh

@tomayac tomayac merged commit d1fb824 into master Jan 22, 2020
8 checks passed
8 checks passed
lint
Details
test
Details
Header rules - excalidraw No header rules processed
Details
Pages changed - excalidraw All files already uploaded
Details
Redirect rules - excalidraw No redirect rules processed
Details
Mixed content - excalidraw No mixed content detected
Details
netlify/excalidraw/deploy-preview Deploy preview ready!
Details
now Deployment has completed
Details
@tomayac tomayac deleted the browser-nativefs branch Jan 22, 2020

input.onchange = () => {
if (!input.files!.length) {
alert("A file was not selected.");

This comment has been minimized.

Copy link
@dwelle

dwelle Jan 22, 2020

Collaborator

We've lost this error handling one alongside this PR. (Also reading the package source, it seems you're not doing this check at all. Is that intentional?).

This comment has been minimized.

Copy link
@tomayac

tomayac Jan 22, 2020

Author Collaborator
This was referenced Jan 22, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants
You can’t perform that action at this time.