mirror of https://github.com/vapor/docs.git
Merge pull request #380 from bellebethcooper/patch-1
Add mention of the need to enable FileMiddleware
This commit is contained in:
commit
a120691065
|
|
@ -38,6 +38,10 @@ the file immediately.
|
|||
For example, a request to `localhost:8080/favicon.ico` will check to see
|
||||
if `Public/favicon.ico` exists. If it does, Vapor will return it.
|
||||
|
||||
You will need to enable `FileMiddleware` in your `configure.swift` file before Vapor can return public files. Make sure you've uncommented this line:
|
||||
|
||||
`middlewares.use(FileMiddleware.self)`
|
||||
|
||||
## Sources
|
||||
|
||||
This folder contains all of the Swift source files for your project.
|
||||
|
|
@ -96,4 +100,4 @@ Learn more about testing in [Testing → Getting Started](../testing/getting-
|
|||
|
||||
## Package.swift
|
||||
|
||||
Finally is SPM's [package manifest](spm.md#package-manifest).
|
||||
Finally is SPM's [package manifest](spm.md#package-manifest).
|
||||
|
|
|
|||
Loading…
Reference in New Issue