fireproofsocks

fireproofsocks

Where can we submit documentation updates to Hex packages?

I know I asked this before (I even submitted a PR somewhere), but now I’ve forgotten the steps because the flow is so obfuscated. Where do interested developers submit changes to the documentation of Hex packages? I may be missing something obvious here, but where are the docs stored? I’m expecting a link to the source code repository that controls the documentation. Instead, the only links I see are irrelevant ones (e.g. ExDoc is generic, not a link to the specific documentation/package that I’m looking at). As someone who is driven to a soapbox when it comes to the importance of writing good documentation (https://medium.com/@craftsmancoding/wtfm-dbbec02eb172), I’m wanting to see a few critical things that appear to be missing in the Hex packages.

1. Where is each packages code’s repo located? If I want to view the source code or fork it, where is the link? Am I to assume the code is always in Github? Bad assumption methinks. Make it clear and put up a link as flagrantly in our faces as possible: This code in this package is stored in this repo: _____

2. Where is the link to the documentation’s repo? Every bit of documentation REQUIRES a feedback loop, no matter if it is an open source package or proprietary code. Every Hex package MUST have a link to where a developer/user can suggest changes to the documentation. Although I’m new to Elixir, I have already seen lots of well-constructed code… but I’ve been forced to slog to some pretty rough-shod docs to get to it. There’s really no excuse for that, and I know I’m not alone in that struggle. Unless there is a clear link for users to submit suggestions to documentation improvements, the adoption of any package or system will suffer because the documentation is static and it stagnates. It’s as dire of a prognosis for a package as having your mouth sewn shut. I think we can do better by implementing a few minor changes.

Thanks!

Most Liked

OvermindDL1

OvermindDL1

I also vote that there should be a link to the hex.pm package page for a given package in the menu for the docs of a project on hexdocs. There have been a number of times where I want to jump back and typing it out manually is long and error prone.

fireproofsocks

fireproofsocks

Thank you for the response!

Ommissions/unclarities or changes to the documentation are considered as implementation bugs by most Elixir developers, so they can be requested in the main project’s issue tracker.

You can see how maddening it is to NOT have the link for that up-front and center. How hard would it modify ExDoc to read the links specified in the mix file and print that up in the top left-hand corner of each page?

joaquinalcerro

joaquinalcerro

I recently contributed to ecto documentation and at first I was confused on how to contribute. This was my first time contributing.

When you go to the “Online Documentation” link, you are presented with a Web Site you assume you can modify or contribute to. Well, at least I did. I even ask someone in the ecto team how can i contribute but never got a response back.

So I wasn’t going to stop investigating how to do it and I found the “</>” button that took me to the Github source code of ecto. Even though I knew about ExDoc and how to document a module inside the same code file, I wasn’t aware that the hex.pm site was built with it.

I finally realized that I had to go the github PR way to contribute and did it.

So based on my experience I recommend you to add a simple “How to contribute to packages/documentation” section in the hex.pm site that will help new contributors. Maybe not experts. This simple section should explain how ExDocs works, what is the “</>” button for and the steps to follow to contribute to any package.

I understand that hex.pm is the package manager for Erlang ecosystem but seems so natural to be guided here on how to contribute to a open source project.

Sorry for the long story… Best regards

ericmj

ericmj

Elixir Core Team

I have opened an issue for this on ex_doc [1]. We also want to add a version selector directly on the hexdocs page so you can jump between versions directly on hexdocs. These features are tricky to implement because hexdocs does not control the content it hosts, documentation is statically generated by ex_doc when the package is published and uploaded to hexdocs which only serves statically generated .html files via AWS S3. So we need to figure out a way to add dynamic content to ex_doc/hexdocs or fundamentally change how they work.

[1] https://github.com/elixir-lang/ex_doc/issues/859.

michalmuskala

michalmuskala

What if ex_doc standardised on having a versions.json part inside of the package and hexdocs would update this file for all released versions when a new version is pushed?

Where Next?

Popular in Questions Top

sergio
In Ruby, I can go: User.find_by(email: "foobar@email.com").update(email: "hello@email.com") How can I do something similar in Elixir? ...
New
_russellb
I want to try my hand at web scraping. What tools/libraries do I need to use. I’m hoping to turn this into something professional so don’...
New
Werner
Hi, I’m using Ubuntu 18.04 and after updating to OTP-24.0 yesterday i have this warning when I run “mix local.hex”: 14:57:30.512 [warn] ...
New
ashish173
I am using Ecto timestamps with postgres, I can see the timestamps() use the :naive_dateime but for my use case I wanted to store the ti...
New
qwerescape
Is there a way to get the call stack or stack trace at any point in the code? Not from exceptions, but an expression that returns how the...
New
fireproofsocks
Forgive me if this is obvious, but how does one delete a database record WITHOUT selecting it first? https://hexdocs.pm/ecto/Ecto.Repo.h...
New
ovidiubadita
Hey all, I discovered Elixir and I love it. I always wanted to learn a functional programming and I intended to go for Haskell, but afte...
New
beno
I will often find my self writing things similar to: case some_value do nil -&gt; something() "" -&gt; something() _ -&gt; someth...
New
Codball
Mix format works fine if run from the cmd. I’ve followed this to facilitate the implementation into VSC which involves downloading an ext...
New
Mooodi
Given a string, how can I get access to its character by index? Enum.at("my_string", 2) doesn't work. Or rather, not char, but a substr...
New

Other popular topics Top

JakeBecker
TL;DR: I’ve just released an implementation of Microsoft’s IDE-independent Language Server Protocol for Elixir. It adds language support ...
1140 51847 244
New
sergio
In Ruby, I can go: User.find_by(email: "foobar@email.com").update(email: "hello@email.com") How can I do something similar in Elixir? ...
New
bsollish-terakeet
Credo is smart enough to check for (something like) this: assert length(the_list) == 0 with this response: Checking if an enum is empt...
New
yawaramin
In the Dialyzer docs ( http://erlang.org/doc/man/dialyzer.html#requesting-or-suppressing-warnings-in-source-files ), there is a way to tu...
New
albydarned
Hello all! I am typing this post from my new MacBook Pro with the M1 chip. I’m loving it so far, and will probably use it as my daily dr...
New
Jim
As a follow up to my earlier question: I have the code compiling and running but not getting a successful login from the rest server. ...
New
polypush135
As many of you may have realized by now (sorry for all the posts here) I’ve been working on a db problem where I’m trying to aggregate a ...
New
aadeshere1
I have a another noob question about loop. Since elixir is immutable, while loop is not directly possible. total = 10 while total != 0 ...
New
shahryarjb
Hello, I have map which I want to convert it to string like this: the map: %{last_name: "tavakkoli", name: "shahryar"} the string I ne...
New
Patoshizzle
After calling mix ecto.create I get this error: 17:00:32.162 [error] GenServer #PID&lt;0.412.0&gt; terminating ** (Postgrex.Error) FATAL...
New

We're in Beta

About us Mission Statement