Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation enhancements from dogfooding(work-in-progress) #63

Open
dixler opened this issue Nov 7, 2022 · 0 comments
Open

Documentation enhancements from dogfooding(work-in-progress) #63

dixler opened this issue Nov 7, 2022 · 0 comments
Labels
documentation Improvements or additions to documentation kind/enhancement Improvements or new features

Comments

@dixler
Copy link
Contributor

dixler commented Nov 7, 2022

Hello!

  • Vote on this issue by adding a 馃憤 reaction
  • If you want to implement this feature, comment to let us know (we'll work with you on design, scheduling, etc.)

Issue details

Currently working on https://github.com/pulumi/home/issues/2311

While using the docs, I have the following nitpicks(work-in-progress):

  • Add the import statements to the README.md it's convenient for copy pasting the entire import string.

I find myself using the following code example https://github.com/pulumi/pulumi-go-provider/blob/main/examples/file/main.go. Comments in the following places could be helpful

  • Possibly add more comments here
    func provider() p.Provider {
    return infer.Provider(infer.Options{
    Resources: []infer.InferredResource{infer.Resource[*File, FileArgs, FileState]()},
    ModuleMap: map[tokens.ModuleName]tokens.ModuleName{
    "file": "index",
    },
    })
    }
  • Could add a comment to detail the purpose of these are type assertions which help create more helpful compilation errors.
    var _ = (infer.CustomDelete[FileState])((*File)(nil))
    var _ = (infer.CustomCheck[FileArgs])((*File)(nil))
    var _ = (infer.CustomUpdate[FileArgs, FileState])((*File)(nil))
    var _ = (infer.CustomDiff[FileArgs, FileState])((*File)(nil))
    var _ = (infer.CustomRead[FileArgs, FileState])((*File)(nil))
    var _ = (infer.ExplicitDependencies[FileArgs, FileState])((*File)(nil))
    var _ = (infer.Annotated)((*File)(nil))
    var _ = (infer.Annotated)((*FileArgs)(nil))
    var _ = (infer.Annotated)((*FileState)(nil))
  • Elaborate on the value that implementing the following interface provides.
    // Annotated is used to describe the fields of an object or a resource. Annotated can be
    // implemented by `CustomResource`s, the input and output types for all resources and
    // invokes, as well as other structs used the above.

Affected area/feature

@dixler dixler added the documentation Improvements or additions to documentation label Nov 7, 2022
@dixler dixler changed the title Documentation enhancements from dogfooding Documentation enhancements from dogfooding(work-in-progress) Nov 7, 2022
@lukehoban lukehoban added the kind/enhancement Improvements or new features label Jul 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation kind/enhancement Improvements or new features
Projects
None yet
Development

No branches or pull requests

2 participants