{"id":20746932,"url":"https://github.com/giscafer/ngx-ace-tern","last_synced_at":"2025-07-24T02:32:13.251Z","repository":{"id":65458351,"uuid":"120858550","full_name":"giscafer/ngx-ace-tern","owner":"giscafer","description":"Tern plugin for Ace Editor  for Angular","archived":false,"fork":false,"pushed_at":"2020-05-01T10:21:38.000Z","size":2348,"stargazers_count":8,"open_issues_count":2,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-24T02:20:19.149Z","etag":null,"topics":["ace","ace-editor","angular","brace"],"latest_commit_sha":null,"homepage":"http://giscafer.github.io/ngx-ace-tern/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/giscafer.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":"2018-02-09T04:58:12.000Z","updated_at":"2020-05-05T02:32:23.000Z","dependencies_parsed_at":"2023-01-24T14:45:18.009Z","dependency_job_id":null,"html_url":"https://github.com/giscafer/ngx-ace-tern","commit_stats":null,"previous_names":["giscafer/ng-ace-tern"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/giscafer/ngx-ace-tern","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/giscafer%2Fngx-ace-tern","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/giscafer%2Fngx-ace-tern/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/giscafer%2Fngx-ace-tern/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/giscafer%2Fngx-ace-tern/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/giscafer","download_url":"https://codeload.github.com/giscafer/ngx-ace-tern/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/giscafer%2Fngx-ace-tern/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265175580,"owners_count":23722667,"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":["ace","ace-editor","angular","brace"],"created_at":"2024-11-17T08:09:57.672Z","updated_at":"2025-07-24T02:32:13.234Z","avatar_url":"https://github.com/giscafer.png","language":"JavaScript","readme":"# ngx-ace-tern\n\n[![npm package](https://img.shields.io/npm/v/ngx-ace-tern.svg)](https://www.npmjs.org/package/ngx-ace-tern)\n\nTern plugin for Ace Editor, base on Angular8.x.\n\n[Online Demo](http://giscafer.github.io/ngx-ace-tern/)\n\ndefault options\n\n```js\n      enableBasicAutocompletion: true,\n      enableLiveAutocompletion: true\n```\n\ndefault mode: `javascript`\n\ndefault theme: `chrome`\n\n# Install\n\n`npm i ngx-ace-tern -S`\n\n## Sample Usage\n\nadd scripts `ace-builds` in your `index.html` or `angular-cli.json`.\n\nyou also can use [brace](https://github.com/thlorenz/brace) instead of ace-builds.\n\n### eg\n\n#### First\n\n```html\n\u003cscript src=\"./assets/ace-builds/src-noconflict/ace.js\"\u003e\u003c/script\u003e\n```\n\nor use [brace](https://github.com/thlorenz/brace) to cleaning angular.json:\n\n```ts\nimport 'brace/index';\nimport 'brace/mode/markdown';\nimport 'brace/theme/github';\nimport 'brace/theme/monokai';\n```\n\n#### Second\n\n```ts\nimport { Component } from '@angular/core';\n\nimport { AceEditorDirective } from 'ngx-ace-tern';\n\n@Component({\n  directives: [AceEditorDirective],\n  template: `\n    \u003cdiv\n      ace-editor\n      [text]=\"text\"\n      [mode]=\"'sql'\"\n      [theme]=\"'clouds'\"\n      [options]=\"options\"\n      [readOnly]=\"false\"\n      (textChanged)=\"onChange($event)\"\n      style=\"display:block; height: 80vh; width:100%\"\n    \u003e\u003c/div\u003e\n  `,\n})\nexport class MyComponent {\n  constructor() {\n    this.text = 'test';\n    this.options = { printMargin: false };\n    this.onChange = (data) =\u003e {\n      console.log(data);\n    };\n  }\n}\n```\n\nImportant pieces to note in the HTML template: `[ace-editor]` attribute, `[text]`, `[theme]`, `[mode]`, `[readOnly]`, `[options]` inputs, `(textChanged)` ,`(editorRef)` output. As per Ace, you must also make it a `display: block;` and give it a width and height.\n\n## Related\n\n- [Ace.Tern](https://github.com/sevin7676/Ace.Tern)\n\n# License\n\nMIT\n\n---\n\n\u003e [giscafer.com](http://giscafer.com) \u0026nbsp;\u0026middot;\u0026nbsp;\n\u003e GitHub [@giscafer](https://github.com/giscafer) \u0026nbsp;\u0026middot;\u0026nbsp;\n\u003e Twitter [@nickbinglao](https://twitter.com/nickbinglao) \u0026nbsp;\u0026middot;\u0026nbsp;\n\u003e Weibo [@Nickbing_Lao](https://weibo.com/laohoubin)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgiscafer%2Fngx-ace-tern","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgiscafer%2Fngx-ace-tern","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgiscafer%2Fngx-ace-tern/lists"}