# Serve static files

@ServerSettings let you to configure a list of static folders.

# Configuration

Configure your server:

import {ServerLoader, ServerSettings} from "@tsed/common";
const rootDir = __dirname;

@ServerSettings({
   rootDir,
   statics: {
      "/": `${rootDir}/webapp`
   }
})
export class Server extends ServerLoader {

}
1
2
3
4
5
6
7
8
9
10
11
12

TIP

serveStatic attributes supports multiple directories