Skip to content

Commit

Permalink
fix website examples
Browse files Browse the repository at this point in the history
  • Loading branch information
arturi committed Aug 31, 2021
1 parent c5edb83 commit 974a976
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ The CSS standards followed in this project closely resemble those from [Medium
### Naming conventions

This project uses naming conventions adopted from the SUIT CSS framework.
[Read about them here](https://github.com/suitcss/suit/blob/main/doc/naming-conventions.md).
[Read about them here](https://github.com/suitcss/suit/blob/master/doc/naming-conventions.md).

To quickly summarize:

Expand Down
8 changes: 5 additions & 3 deletions website/src/examples/xhrupload/app.es6
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,20 @@ const FileInput = require('@uppy/file-input')
const XHRUpload = require('@uppy/xhr-upload')
const ProgressBar = require('@uppy/progress-bar')

document.querySelector('.Uppy').innerHTML = ''

const uppy = new Uppy({ debug: true, autoProceed: true })
uppy.use(FileInput, {
target: '.UppyForm',
target: '.Uppy',
})
uppy.use(ProgressBar, {
target: '.UppyProgressBar',
hideAfterFinish: false
hideAfterFinish: false,
})
uppy.use(XHRUpload, {
endpoint: 'https://xhr-server.herokuapp.com/upload',
formData: true,
fieldName: 'files[]'
fieldName: 'files[]',
})

// And display uploaded files
Expand Down
4 changes: 2 additions & 2 deletions website/src/examples/xhrupload/app.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<!-- Basic Uppy styles -->
<link rel="stylesheet" href="/uppy/uppy.min.css">

<div class="UppyForm">
<form action="https://xhr-server.herokuapp.com/upload">
<div class="Uppy">
<form action="https://xhr-server.herokuapp.com/upload" method="post">
<h5>Uppy was not loaded — slow connection, unsupported browser, weird JS error on a page — but the upload still works, because HTML is cool like that</h5>
<input type="file" name="files[]" multiple="">
<button type="submit">Fallback Form Upload</button>
Expand Down

0 comments on commit 974a976

Please sign in to comment.