feathersjs / docs

[MOVED] Legacy Feathers documentation
https://crow.docs.feathersjs.com/
MIT License
242 stars 532 forks source link

docs: add hook-less service method description #1498

Closed bwgjoseph closed 4 years ago

bwgjoseph commented 4 years ago

Currently, the only place learn about hook-less service method is at https://docs.feathersjs.com/guides/migrating.html#hook-less-service-methods and it isn't obvious when looking through the docs..

I have added it to api/databases/common at the top after constructor but not sure if it should be at the bottom after adapter.remove(id, params). What do you think?

This was brought up by Mike from slack...

mikestefanello commented 4 years ago

The hook-less service methods were useful for me because I was attempting to load the requested object from within hooks, and it would result in an infinite loop:

const obj = await context.service.get(context.id);

Using _get avoids that.

daffl commented 4 years ago

Great call, thank you!