Skip to content

Make sure all code examples containing an entry point use library feature #67

Closed
@aumetra

Description

@aumetra

Follow-up to #57 (comment)

We should probably enforce the convention of having a library feature in contracts by putting them explicitly into every code sample and reinforcing that this is how it should be done.

Also, as @chipshort mentioned, people will probably copy-paste from the docs a lot, so having that library feature everywhere means that they will follow best practices.


One open question is how to enforce this in CI. An idea I had was a simple CI step that greps across the extracted tests for ^#\[entry_point\] and errors out when it gets hit (something like that)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions