Can we write such code in next?
Answered
New Zealand posted this in #help-forum
New ZealandOP
/component/actions.ts
'use server'
function foo {...}
/app/api/some-get.ts
function GET() {
...
foo()
...
}
Answered by B33fb0n3
yes, the server action then would be translated to a normal function