https://github.com/candyframework/candy-deno
candyjs deno version
https://github.com/candyframework/candy-deno
Last synced: about 5 hours ago
JSON representation
candyjs deno version
- Host: GitHub
- URL: https://github.com/candyframework/candy-deno
- Owner: candyframework
- License: mit
- Created: 2025-01-20T06:33:53.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2025-03-13T03:34:53.000Z (over 1 year ago)
- Last Synced: 2025-03-13T04:26:19.862Z (over 1 year ago)
- Language: TypeScript
- Size: 131 KB
- Stars: 0
- Watchers: 6
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## An object-oriented efficient MVC and RESTful framework
This project is rewritten based on the architecture of Project [CandyJs](https://github.com/candyframework)
## Quick start
CandyJs application start with an entry file
```typescript
import type HttpRequest from '@candy/framework/http/HttpRequest';
import Main from '@candy/framework';
import Application from '@candy/framework/rest/Application';
import HttpResponse from '@candy/framework/http/HttpResponse';
const app = new Application({
id: 'rest',
debug: true,
});
app.get('/', async (_request: HttpRequest) => {
return HttpResponse.fromText('Hello, world!');
});
app.get('/user/{id}', async (_request: HttpRequest, parameters: any) => {
return HttpResponse.fromText('User ' + parameters.id);
});
const main = new Main(app);
main.listen({
port: 2333,
});
```