Skip to content
This repository has been archived by the owner on Mar 22, 2022. It is now read-only.
/ url-parser Public archive

Desafio para parte 1 de treinamento de testes em JavaScript

Notifications You must be signed in to change notification settings

quero-edu/url-parser

Repository files navigation

URL Parser

This project is not meant to be a fully featured URL parser. It is a naive solution proposed during an unit test training session.

Parses URL in the following format: protocol://user:pass@host:1000/some/path?query=string#hash

const parse = require('url-parser');

parse('mysql://jos%C3%A9:[email protected]:3306/some/path?option=value#spam')
// {
//   protocol: 'mysql',
//   auth: { username: 'josé', password: 'maria' },
//   hostname: 'database.com',
//   port: '3306',
//   path: '/some/path',
//   query: { option: 'value' },
//   hash: 'spam'
// }

About

Desafio para parte 1 de treinamento de testes em JavaScript

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published