Use 'type' instead of code and action
Update readme.