npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

md-links-jllanjech

v1.1.0

Published

Md-Links te ayudará a verificar si los links que estén en los archivos .md sirven o ya están invalidados.

Downloads

7

Readme

Markdown Links

Índice


1. Descripción


¿Para qué puede servir?

2. Planificación del proyecto


3. Flujograma de actividades


Se desarrolló a través de diagramas de flujo los procesos del API y CLI que competen para la realización del proyecto.

4. Instrucciones de uso


En esta sección te brindaré la información de cómo puedes instalar esta libreria para que poder usarla. Las rutas que ingresas puede ser relativa como absoluta.

Instalación

Puedes instalarlo ingresando esta línea de comando en tu terminal:

npm i md-links-jllanjech

Uso

Una vez culminada la instalación de las dependencias en tu proyecto, puedes ejecutar la librería ingresando md-links seguido de la ubicación en donde se encuentra el archivo o directorio a analizar.

md-links <ubicación de archivo/directorio>

Esto te retornará:

Ejemplo:

$ md-links ./test_directory/links.md

href: https://www.youtube.com/watch?v=ixcjgxsN_3Q
text: https://www.youtube.com/watch?v=ixcjgxsN_3Q
file: C:\Users\USER\Documents\LIM017-md-links\test_directory\links.md


href: https://es.acervolima.com/node-js-process-argv-propiedad/
text: https://es.acervolima.com/node-js-process-argv-propiedad/
file: C:\Users\USER\Documents\LIM017-md-links\test_directory\links.md

Opciones adicionales

Adicionalmente puedes colocar otros comandos como --validate , --stats o ambos a la vez para darte mayor detalle de los links encontrados.

1 md-links <ubicación de archivo/directorio> --validate
2 md-links <ubicación de archivo/directorio> --stats
3 md-links <ubicación de archivo/directorio> --validate --stats

1. --validate:

Si ingresas este comando adicional tendrás como valores de retorno:

Ejemplo:

$ md-links ./test_directory/links.md/links.md --validate

href: https://www.youtube.com/watch?v=ixcjgxsN_3Q 
text: https://www.youtube.com/watch?v=ixcjgxsN_3Q 
file: C:\Users\USER\Documents\LIM017-md-links\test_directory\links.md
status: 200 
message: Ok

href: https://google.com/404-error-page
text: https://google.com/404-error-page
file: C:\Users\USER\Documents\LIM017-md-links\test_directory\links.md
status: 404
message: Fail

2. --stats:

Si pasamos esta opción tendremos las estadísticas básicas sobre los links como el total de ellos y cuántos son únicos.

Ejemplo:

$ md-links ./test_directory/links.md --stats
Total: 2 Unique: 2

3. --validate --stats:

O en su defecto --stats --validate , te retornará la totalidad de links, los únicos y cuánto de ellos son inservibles.

Ejemplo:

$ md-links ./test_directory/links.md --validate --stats
Total: 2 Unique: 2 Broken: 1

4. --help:

Si no recuerdas ninguno de las opciones antes descritos, puedes ayudarte con este comando.

Ejemplo:

$ md-links ./test_directory/links.md --help

                                ▐▓█▀▀▀▀▀▀▀▀▀█▓▌░▄▄▄▄▄░
                                ▐▓█░░▀░░▀▄░░█▓▌░█▄▄▄█░
                                ▐▓█░░▄░░▄▀░░█▓▌░█▄▄▄█░
                                ▐▓█▄▄▄▄▄▄▄▄▄█▓▌░█████░
                                ░░░░▄▄███▄▄░░░░░█████░
_____________________________________________________________________________________________
                                    H E L P 
You can place the following commands to have statistics of the links found in your md files:
--validate: Show the link, text, route, status and status message.
--stats: Show statistics about the links found such as unique links and unique links.
--stats --validate: Show total statistics of the number of links, unique links and broken 
links Use the next structure in the commands line: mdLinks <path> <command> but you want can 
only and it ill show you the link, text and the file where it is located.
_____________________________________________________________________________________________

5. --about:

Y si deseas saber la descripción de esta libreria poderosa, puedes ejecutar esta opción que te llevará a mi repositorio para mayor información.

$ md-links ./prueba2/doc.md --about


                                ▐▓█▀▀▀▀▀▀▀▀▀█▓▌░▄▄▄▄▄░
                                ▐▓█░░▀░░▀▄░░█▓▌░█▄▄▄█░
                                ▐▓█░░▄░░▄▀░░█▓▌░█▄▄▄█░
                                ▐▓█▄▄▄▄▄▄▄▄▄█▓▌░█████░
                                ░░░░▄▄███▄▄░░░░░█████░

            ███╗   ███╗██████╗     ██╗     ██╗███╗   ██╗██╗  ██╗███████╗
            ████╗ ████║██╔══██╗    ██║     ██║████╗  ██║██║ ██╔╝██╔════╝
            ██╔████╔██║██║  ██║    ██║     ██║██╔██╗ ██║█████╔╝ ███████╗
            ██║╚██╔╝██║██║  ██║    ██║     ██║██║╚██╗██║██╔═██╗ ╚════██║
            ██║ ╚═╝ ██║██████╔╝    ███████╗██║██║ ╚████║██║  ██╗███████║
            ╚═╝     ╚═╝╚═════╝     ╚══════╝╚═╝╚═╝  ╚═══╝╚═╝  ╚═╝╚══════╝
            ____________________________________________________________

            It is a command line interface (CLI) that helps the user to 
            check if the Mark down (md) files contain links and if they 
            work or not. Created by Juana LC, my repository:
            https://github.com/Juana-89/LIM017-md-links
            ____________________________________________________________

5. Aviso de errores


Si ingresas erróneamente la ruta de un directorio o archivo que no existe, la línea de comandos te retornará el siguiente mensaje de error:

$ md-links ./Documents/noexist.md
Path no exists

De no haber archivos MD te mostrará este aviso de error:

$ md-links ./Documents
There are not files MD

Y de haber archivos MD pero dentro de ellos no hay links, en la terminal te saldrá lo siguiente:

$ md-links ./Documents1
There are not links

6. Herramientas usadas


Node.js FS Path module Node-fetch Marked.js Colors Npm

Autora


@jllanjech