`
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
βββββββββββ Welcome to ββββββββββββββ
βββββββββββ βββββ ββββ ββ βββ βββ ββββ βββ βββ ββββββββββββββ
βββββββββββ βββββ ββββ ββ βββ βββ ββββ βββ βββ ββββββββββββββ
βββββββββββ βββββ ββββ ββ βββ βββ ββββ βββ ββββββββββββββββββ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
βββββββββββββββββββββββββββββββββββββββββββββββ . . . βββ
βββββββββββββββββββββββββββββββββββββββββββββββ aw βββ
βββββββββββββββββββββββββββββββββββββββββββββββ yeaah !! βββ
βββββββββββββββββββββββββββββββββββββββββββββββ . . . βββ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ`
Markdown is a very popular lightweight markup language among developers. It is used in many platforms that handle plain text (GitHub, forums, blogs, ...), and it is very common to find several files in that format in any type of repository (starting with the traditional README.md).
These Markdown files usually contain links that are often broken or no longer valid and that greatly damages the value of the information that you want to share.
In this project, md-links
is an executable that reads and analyzes files in Markdown format, to verify the links they contain and report some statistics.
Options:
--validate
(OK, Fail)--stats
(total, unique, broken)
Install this library with this command :
npm install mysticbel-mdlinks
or you can also download it from github:
npm install mysticbel/LIM015-md-links
// Usage:
md-links <path-to-file> [options]
// Commands:
--v, --validate Show validate links, makes an HTTP request to find out if the link works or not
--s, --stats Show basic statistics about links
--v --s Show statistics about links : total, unique, broken
--validate --stats Show statistics about links : total, unique, broken
// Global options:
-h, --help display help for command
If we pass the --validate
option, the module must make an HTTP request to find out if the link works or not. If the link results in a redirect to a URL that responds ok, then we will treat the link as ok.
If we pass the --stats
option, the output will be a text with basic statistics about the links.
We can also combine --stats
and --validate
to obtain needed statistics from the validation results.
If we pass the --help
option, the output will be a help menu with all commands.
If we pass a non existant option, the output will be a help menu with an 'invalid command' message.
If we do not pass any option(s) , the output will be a 'links not found' message and the path doesn't exist.
the output will be an array with all the links extracted from the file.
I love using Github Projects !! π
- [βοΈπ±] Can be installed via
npm install --global <github-user>/md-links
- [βοΈπ³] A board with the backlog for the implementation of the library.
- [βοΈπ³] Technical documentation of the library.
- [βοΈπ³] Library installation and use guide.
- [βοΈπΌ] The module exports a function with the expected interface (API).
- [βοΈπΌ] Implement single file support.
- [βοΈπΌ] Implement directory support.
- [βοΈπΌ] Implement
options.validate
- [βοΈπ¦] Exposes executable
md-links
in the path (configured inpackage.json
) - [βοΈπ¦] Runs without errors / expected output
- [βοΈπ¦] Implement
--validate
- [βοΈπ¦] Implement
--stats
- [βοΈπ±] Unit tests cover a minimum of 70% of statements, functions, lines, and branches.
- [βοΈπ±] Pass tests (and linters) (
npm test
).
- Acerca de Node.js - DocumentaciΓ³n oficial
- Node.js file system - DocumentaciΓ³n oficial
- Node.js http.get - DocumentaciΓ³n oficial
- Node.js - Wikipedia
- What exactly is Node.js? - freeCodeCamp
- ΒΏQuΓ© es Node.js y para quΓ© sirve? - drauta.com
- ΒΏQuΓ© es Nodejs? Javascript en el Servidor - Fazt en YouTube
- ΒΏSimplemente quΓ© es Node.js? - IBM Developer Works, 2011
- Node.js y npm
- MΓ³dulos, librerΓas, paquetes, frameworks... ΒΏcuΓ‘l es la diferencia?
- AsΓncronΓa en js
- NPM
- Publicar packpage
- Crear mΓ³dulos en Node.js
- Leer un archivo
- Leer un directorio
- Path
- Linea de comando CLI
'md-links' is a project done by Maribel Maza for Laboratoria ,
October 2021 π€
Β