[x] remove reading & writing cursor directly in sink
Some sinks will need to validate the incoming data before saving the cursor, saving the cursor prior to validation can cause data loss
[x] export fileCursor & httpCursor
import { setup, fileCursor } from "substreams-sink"
...
// Get cursor from file
const cursor = fileCursor.readCursor("cursor.lock");
// Setup sink for Block Emitter
const { emitter } = await setup({...options, cursor});
...
// Save new cursor on each new block emitted
fileCursor.onCursor(emitter, "cursor.lock");
fileCursor
&httpCursor
--http-cursor-auth
&--cursor-path
params--cursor
paramstartCursor
fromsetup