Skip to content

Commit 3f9e3c2

Browse files
committed
updated readme
1 parent 92e6a6a commit 3f9e3c2

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

README.md

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,28 +23,32 @@ It will provide a simple webpage for updating the firmware or filesystem of `ESP
2323

2424
### Setup
2525
1. Include the library after `ESPAsyncWebServer.h`
26-
```
26+
``` C++
2727
#include <ESPAsyncWebServer.h>
2828
#include <ESPAsyncHTTPUpdateServer.h>
2929
```
3030
2. Create an object from `ESPAsyncHTTPUpdateServer`
31-
```
31+
``` C++
3232
ESPAsyncHTTPUpdateServer _updateServer;
3333
AsyncWebServer _server(80);
3434
```
3535
3. Setup the update server before starting the webServer
36-
```
36+
``` C++
3737
_updateServer.setup(&_server);
3838
_server.begin();
3939
```
4040
#### Custom Route
41-
```
41+
``` C++
4242
_updateServer.setup(&_server, "/customroute");
4343
```
4444
#### Credentials
45-
```
45+
``` C++
4646
_updateServer.setup(&_server, "username", "password");
4747
```
48+
or
49+
``` C++
50+
_updateServer.setup(&_server, "/customroute", "username", "password");
51+
```
4852

4953
> [!IMPORTANT]
5054
> ### Selecting FileSystem

0 commit comments

Comments
 (0)