更優雅的 node.js 框架 :nestjs 5.1 發佈 ,支持異步動態 modules 。

Nest是構建高效,可擴展的 Node.js Web 應用程序的框架。 它使用現代的 JavaScript 或 TypeScript(保留與純 JavaScript 的兼容性),並結合 OOP(面向對象編程),FP(函數式編程)和FRP(函數響應式編程)的元素。ios

在底層,Nest 使用了 Express,但也提供了與其餘各類庫的兼容,例如Fastify,能夠方便地使用各類可用的第三方插件。編程

Features

common: FileFieldsInterceptor upload multiple files with different names (multer.fields) #741
core: support async dynamic modules #800
core: exclude routes in the MiddlewareBuilder #790
core: support RouteInfo in the MiddlewareBuilder (restrict middleware to certain request method)axios

forRoutes(
   { path: 'cats', method: RequestMethod.GET },
   { path: 'cats', method: RequestMethod.POST },
)

Bug Fixes

common: empty body ends up with 500 error (ValidationPipe) #734
core: the last one of APP_ providers get registered #812
core: middleware runs more than once #779
core: custom decorators not being treated as default ones #765
microservices: allow gRPC stream cancellation #773框架

Improvements

common: expose axiosRef from HttpService#842
common: make MiddlewareFunction generic #778
microservices: propagate internal gRPC error #844
testing: type signature for TestModule.get() is too restrictive #772async

文檔

要查看 指南, 請訪問 docs.nestjs.cn. books
要查看 English指南, 請訪問 docs.nestjs.com. bookside

相關文章
相關標籤/搜索