GithubHelp home page GithubHelp logo

Doc block guidelines about zubr HOT 7 OPEN

nkkollaw avatar nkkollaw commented on July 20, 2024
Doc block guidelines

from zubr.

Comments (7)

ddziaduch avatar ddziaduch commented on July 20, 2024

hm, good idea 👍

from zubr.

nkkollaw avatar nkkollaw commented on July 20, 2024

@radmen ..?

from zubr.

nkkollaw avatar nkkollaw commented on July 20, 2024

...it might also make sense to always have the "NOTE" part, so even if the function didn't change from the original:

/**
 * @link http://php.net/manual/en/function.xxx.php
 *
 * NOTE: no change
 */

from zubr.

ddziaduch avatar ddziaduch commented on July 20, 2024

Ok, my proposal - @link tag for every function - but the functions with different order should use @param tag - @nkkollaw what about that?

from zubr.

nkkollaw avatar nkkollaw commented on July 20, 2024

Yes, if functions have changes we have to document them with @param, @return if we return something different, etc.

I will create an example and put it in the CONTRIBUTING file.

from zubr.

radmen avatar radmen commented on July 20, 2024

I'd say that we should keep bare minimum:

  • Short description - usually the first line from php.net (eg for strstr: Find the first occurrence of a string)
  • @param
  • @return
  • @link to docs on php.net

(sorry for late response, I'm still on vacation till end of week)

from zubr.

nkkollaw avatar nkkollaw commented on July 20, 2024

I'd say that we should keep bare minimum

I don't know if we have to document PHP's functions. I think it's more useful to describe what we change, since we expect our target to know what they're doing if they're using and feel the need for this kind of library.

Personally, I'm fine with @param etc. if they're already there (e.g., if adding them doesn't slow us down0, but the description I would along the lines of:

No change from original (see php.net/strstr)

or:

NOTE: we switched $haystack with $needle as per our guidlines

sorry for late response, I'm still on vacation till end of week

No problem!

from zubr.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.