{"id":15018408,"url":"https://github.com/nativescript/nativescript-tslint-rules","last_synced_at":"2025-03-25T13:34:10.749Z","repository":{"id":141979459,"uuid":"175190685","full_name":"NativeScript/nativescript-tslint-rules","owner":"NativeScript","description":"A set of TSLint rules for NativeScript projects.","archived":false,"fork":false,"pushed_at":"2019-10-29T18:14:49.000Z","size":28,"stargazers_count":4,"open_issues_count":0,"forks_count":1,"subscribers_count":26,"default_branch":"master","last_synced_at":"2025-03-24T20:28:46.216Z","etag":null,"topics":["nativescript","tslint","typescript"],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/NativeScript.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2019-03-12T10:48:15.000Z","updated_at":"2024-05-30T16:35:17.000Z","dependencies_parsed_at":null,"dependency_job_id":"c8704c5e-32d0-44f5-9307-01fbd512f96c","html_url":"https://github.com/NativeScript/nativescript-tslint-rules","commit_stats":{"total_commits":32,"total_committers":2,"mean_commits":16.0,"dds":0.21875,"last_synced_commit":"875118e3f0cb36a06ac5ca0b5a6e29bdcef7ea8f"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NativeScript%2Fnativescript-tslint-rules","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NativeScript%2Fnativescript-tslint-rules/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NativeScript%2Fnativescript-tslint-rules/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NativeScript%2Fnativescript-tslint-rules/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/NativeScript","download_url":"https://codeload.github.com/NativeScript/nativescript-tslint-rules/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245471536,"owners_count":20620957,"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":["nativescript","tslint","typescript"],"created_at":"2024-09-24T19:51:55.811Z","updated_at":"2025-03-25T13:34:10.392Z","avatar_url":"https://github.com/NativeScript.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NativeScript TSLint Rules\n\n[![Build Status](https://travis-ci.org/NativeScript/nativescript-tslint-rules.svg?branch=master)](https://travis-ci.org/NativeScript/nativescript-tslint-rules)\n\nThis project contains tslint rules useful for NativeScript applications.\n\n## `prefer-mapped-imports` rule\n\nPrefer using mapped paths when importing external modules or ES6 import declarations.\n\n\u003e Note: This rule is intended for [code-sharing NativeScript projects](https://docs.nativescript.org/code-sharing/intro)\n\n### Options\n\n-   `prefix` specifies the prefix for the mapped imports (usually \"@src/\").\n-   `prefix-mapped-to` specifies folder that is mapped to the prefix (usually \"src/\").\n-   `base-url` specifies the base url of the typescript program (usually \".\")`\n\nSample rule config (`tslint.json`):\n\n```\n\"prefer-mapped-imports\": [\n    true,\n    {\n        \"prefix\": \"@prefix/\",\n        \"prefix-mapped-to\": \"src/\",\n        \"base-url\": \".\"\n    }\n]\n```\n\n### Autofix\n\nThe rule will propose a fix if:\n\n-   Has all the configurations in the `tslint.json`\n-   Used in typescript project with `baseUrl` and `path` mappings for either web or mobile files.\n\n## `no-android-resources` rule\n\nThe rule forbids using constants inside `android.R` as they cause performance issues.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnativescript%2Fnativescript-tslint-rules","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnativescript%2Fnativescript-tslint-rules","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnativescript%2Fnativescript-tslint-rules/lists"}