{"id":13528015,"url":"https://github.com/MicrosoftEdge/static-code-scan","last_synced_at":"2025-04-01T11:30:47.427Z","repository":{"id":9699885,"uuid":"11649862","full_name":"MicrosoftEdge/static-code-scan","owner":"MicrosoftEdge","description":"Run this quick static code scan on any URL to check for out-of-date libraries, layout issues and accessibility.","archived":true,"fork":false,"pushed_at":"2017-10-25T00:03:54.000Z","size":1433,"stargazers_count":1047,"open_issues_count":0,"forks_count":228,"subscribers_count":118,"default_branch":"master","last_synced_at":"2024-11-02T13:34:08.618Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"tensorflow/tensorflow","license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MicrosoftEdge.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-07-25T02:12:35.000Z","updated_at":"2024-10-12T12:29:16.000Z","dependencies_parsed_at":"2022-07-07T22:48:54.830Z","dependency_job_id":null,"html_url":"https://github.com/MicrosoftEdge/static-code-scan","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MicrosoftEdge%2Fstatic-code-scan","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MicrosoftEdge%2Fstatic-code-scan/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MicrosoftEdge%2Fstatic-code-scan/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MicrosoftEdge%2Fstatic-code-scan/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MicrosoftEdge","download_url":"https://codeload.github.com/MicrosoftEdge/static-code-scan/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246631581,"owners_count":20808711,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-01T06:02:10.148Z","updated_at":"2025-04-01T11:30:46.764Z","avatar_url":"https://github.com/MicrosoftEdge.png","language":"JavaScript","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"readme":"# THIS PROJECT IS DEPRECATED\n\nThis project is deprecated and no longer maintained. Please check [sonar](https://github.com/sonarwhal/sonar) if you need a similar tool but more flexible and modern.\n\n# Static Scan\n\nThis tool analyzes the HTML, CSS, and JavaScript of a site or application for common coding issues.\nIt warns about practices such as incomplete specification of CSS properties, invalid or incorrect\ndoctypes, and obsolete versions of popular JavaScript libraries.\n\nIt's easiest to use modern.IE by going to the [modern.IE site](https://dev.windows.com/en-us/microsoft-edge/tools/staticscan/)\nand entering the URL to scan there. To customize the scan, or to use the scan\nto process files behind a firewall, you can clone and build the files from this repo\nand run the scan locally.\n\n## How it works\n\nThe modern.IE local scan runs on a system behind your firewall; that system must have\naccess to the internal web site or application that is to be scanned.\nOnce the files have been analyzed, the analysis results are sent back to the modern.IE\nsite to generate a complete formatted report that includes advice on remediating any issues.\nThe report generation code and formatted pages from the modern.IE site are not included in this repo.\n\nSince the local scan generates JSON output, you can alternatively use it as a standalone scanner\nor incorporate it into a project's build process by processing the JSON with a local script.\n\nThe main service for the scan is in the `app.js` file; it acts as an HTTP server.\nIt loads the contents of the web page and calls the individual tests, located in `/lib/checks/`.\nOnce all the checks have completed, it responds with a JSON object representing the results.\n\n## Installation and configuration\n\n* [Install node.js](https://github.com/joyent/node/wiki/Installation). You can use a [pre-compiled Windows executable](https://github.com/joyent/node/wiki/Installation#installing-on-windows) if desired. Version 0.10 or higher is required.\n* If you want to modify the code and submit revisions, [Install git](http://git-scm.com/downloads). You can choose [GitHub for Windows](http://windows.github.com/) instead if you prefer. Then clone this repository. If you just want to run locally then downloading then you just need to download the latest version from [here](https://github.com/InternetExplorer/modern.IE-static-code-scan/archive/master.zip) and unzip it\n* Install dependencies. From the Modern.ie subdirectory, type: `npm install`\n* If desired, set an environment variable `PORT` to define the port the service will listen on. By default the port number is 1337. The Windows command to set the port to 8181 would be: `set PORT=8181`\n\n### CLI\nThe scanner has a CLI interface that prints directly the results for a website. You just have to run the following command to use it:\n\n```\nstatic-code-scan\n```\n\n![demo](https://cloud.githubusercontent.com/assets/4303/10773742/6a4f47d6-7cba-11e5-9d25-7da62fb66edd.gif)\n\nNote: Windows users may need to navigate to the Modern.ie subdirectory and type `npm link` to get the `static-code-scan` command to work.\n\n### Via browser\n\n* Start the scan service: From the Modern.ie subdirectory, type: `node app.js` and the service should respond with a status message containing the port number it is using.\n* Run a browser and go to the service's URL; assuming you are using the default port and are on the same computer, the URL would be: `http://localhost:1337/`\n* Follow the instructions on the page.\n\n## Testing\n\nThe project contains a set of unit tests in the `/test/` directory. To run the unit tests, type `grunt nodeunit`.\n\n## JSON output\n\nOnce the scan completes, it produces a set of scan results in JSON format:\n```js\n{\n    \"testName\" : {\n        \"testName\": \"Short description of the test\",\n        \"passed\" : true/false,\n        \"data\": { /* optional data describing the results found */ }\n    }\n}\n```\n\nThe `data` property will vary depending on the test, but will generally provide further detail about any issues found.\n\n## Code of Conduct\nThis project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FMicrosoftEdge%2Fstatic-code-scan","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FMicrosoftEdge%2Fstatic-code-scan","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FMicrosoftEdge%2Fstatic-code-scan/lists"}