https://github.com/j-m/browsability
🌐✔❌Browser compatibility analyser
https://github.com/j-m/browsability
browser cli compatibility css html javascript mdn mdn-data
Last synced: 9 months ago
JSON representation
🌐✔❌Browser compatibility analyser
- Host: GitHub
- URL: https://github.com/j-m/browsability
- Owner: j-m
- License: mit
- Created: 2018-02-24T10:40:35.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2023-04-19T14:30:53.000Z (about 3 years ago)
- Last Synced: 2025-01-31T14:51:14.686Z (over 1 year ago)
- Topics: browser, cli, compatibility, css, html, javascript, mdn, mdn-data
- Language: TypeScript
- Homepage:
- Size: 2.87 MB
- Stars: 4
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Security: SECURITY.md
Awesome Lists containing this project
README
## About
Scan your HTML, CSS, and JavaScript to find out the minimum browser version that you support.
No guessing. No arduous tests. Just data.
Browsability is designed to be run as a CLI tool, no webdrivers or complex emulation. For now, we use just [MDN's compatibility data](https://github.com/mdn/browser-compat-data), so you can only assess [these browsers](https://github.com/mdn/browser-compat-data/tree/master/browsers).
## Quick links
[Roadmap](https://github.com/j-m/browsability/projects/1)
[Changelog](./docs/changelog.md)
[Docs](./docs)
## Getting Started
### Installation
```txt
npm i -D browsability
```
### Commands
```txt
browsability -v (or --version) (Output Browsability version)
browsability -h (or --help) (Output the help information)
browsability --init (Copy Browsability template to relative or absolute path)
browsability (Glob pattern of files to run Browsability against )
browsability (Run with default settings)
```
Where `` is a relative (starting with `./`) or absolute filepath.
Where `` is any combination of the **optional** arguments:
```txt
-s (or --silent) (No console output)
-c (or --config) (Configuration file location)
-f (or --full) (Report minimum version for all browsers, not just those configured)
```
### Settings
Refer to [the docs](./docs/settings.md) for all options and what each command could throw.
Example `.browsability.js` file:
```js
[{
scope: 'full' // 'full': assess everything. 'diff': assess changes only (requires git)
css: true // Assess CSS
html: true // Assess HTML
javascript: true // Assess JavaScript
include: [ // List of files to scan. Glob enabled
"./**/*"
]
exclude: [ // List of files to exclude from the scan. Glob enabled
"**/node_modules/**"
]
versions: { // The minimum browser version that your project must support
chrome: 62
safari: "current" // Matches the 'status' attributes in `mdn/browser-compat-data/browsers`
edge: 16
ie: 11
},
assess: [ // Find minimum browser version support without throwing. e.g. 'all' or ['firefox']
'firefox'
]
}]
```
## Contributors
|[
j-m](https://github.com/j-m/)|[
jmsv](https://github.com/jmsv/) |
|:-:|:-:|