move source-def inside client code and add source-inline