How use custom imageryProvider

Hi, how can i use my own imageryProvider? Should i rebuild cesiumjs for it or create as plugin (any tutorials)?