Buckets:
| const fastify = require('../fastify')({ logger: true }) | |
| const opts = { | |
| schema: { | |
| response: { | |
| '2xx': { | |
| type: 'object', | |
| properties: { | |
| greet: { type: 'string' } | |
| } | |
| } | |
| } | |
| } | |
| } | |
| fastify.register(function (instance, options, done) { | |
| // the route will be '/english/hello' | |
| instance.get('/hello', opts, (req, reply) => { | |
| reply.send({ greet: 'hello' }) | |
| }) | |
| done() | |
| }, { prefix: '/english' }) | |
| fastify.register(function (instance, options, done) { | |
| // the route will be '/italian/hello' | |
| instance.get('/hello', opts, (req, reply) => { | |
| reply.send({ greet: 'ciao' }) | |
| }) | |
| done() | |
| }, { prefix: '/italian' }) | |
| fastify.listen({ port: 8000 }, function (err) { | |
| if (err) { | |
| throw err | |
| } | |
| }) | |
Xet Storage Details
- Size:
- 763 Bytes
- Xet hash:
- 291297d46d3b92f06899c7a4a89a037ad7bd6800b9c835af3eda576a26859f5e
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.