Originally published on strongloop.com
We bring another month of new features, fixes, and improvements in documentation and developer experience in LoopBack. Make sure to update your compatible projects with lb4 update
if you want to update the underlying libraries to their latest versions.
Also, as part of our long-term effort to encourage more community contributions, we are participating in this year’s Hacktoberfest. You can read more about the event and participation details at our Hacktoberfest blogpost.
Documentation Enhancements
There has been a continuous effort to improve our documentation. Below are some highlights for this month:
- A new documentation page, Accessing HTTP request and response objects, was added explaining the various ways and places to access the request and response objects.
- We are working on a series of troubleshooting guides for LoopBack. This month we completed the basic guide and Debugging tests with Mocha. A few more areas that can be added to the guide.
- We added an example app demonstrating LoopBack 4's context binding resolution and dependency injection within a context hierarchy.
New Experimental Features
- We have created a GraphQL extension that provides integration with GraphQL using type-graphql. Check out the GraphQL example app for a sample app.
- We added support for parsing MessagePack bodies. For usage, refer to the documentation.
Investigation on Better Handling of ObjectID in MongoDB
We spent a good amount of time to improve the experience of using ObjectID
with LoopBack. We have identified the direction we want to take and the tasks to work on. You can learn more about the spike in issue 3456.
Fixes and Improvements
- added
.onStart()
and.onStop()
methods of theApplication
, so that they can be used to register observers as plain functions for the start and stop life-cycle events. - enhanced the
lb4 update
command to be runnable against any projects that use@loopback/*
dependencies independencies
ordevDependencies
, orpeerDependencies
; not just LoopBack 4 projects. - included the application build when running
migrate
andopenapi-spec
scripts. - added
@injectable
, so that@injectable
can be used instead of@bind
, which is in tune with other frameworks using Dependency Injection.@bind
is not removed from the framework, so apps using@bind
will not be affected. - made the
keepAliveTimeout
,headersTimeout
,maxConnections
,maxHeadersCount
, andtimeout
properties of the underlying HTTP server instance configurable by specifying them in the application config object. - updated the generated application directory name during application scaffolding when application names involve numbers
- added the ability to boot dynamic value provider classes and classes with
@inject
. - removed the
extension-
prefix from the affected extensions for their names to be consistent with other extension modules. - improved the overall experience of graphql configuration and subscriptions in LoopBack.
- added the support of OpenAPI parameter AJV validation on simple types and AJV formats for OpenAPI spec data type formats.
- updated the REST middleware so that it can now cached by the use of singleton binding scope.
- added Twitter example in the Passport login example app.
Community Contributions
Shout out to Rifa Achrinza for explaining the differences between weak and strong relations in PR 6404, MessagePack PR, and his numerous other PRs.
Opening issues are community contributions too, so thanks to all those who help LoopBack become better by reporting bugs and usability issue. We try to address popular issues with higher priority, so continue to let us know the problems you face on GitHub or Slack.
Enriching LoopBack and its Community - You are Invited!
As mentioned in our recent blog post, your contribution is important to make LoopBack a sustainable open source project.
Here is what you can do:
- Join LoopBack Slack community
- Look for first-contribution-friendly issues
- Give us feedback and join our discussion in our GitHub repo
Let's make LoopBack a better framework together!