Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8860515
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T15:16:53+00:00 2026-06-14T15:16:53+00:00

Angular provides the instance element of the current scope within a link function. The

  • 0

Angular provides the instance element of the current scope within a link function.

The iElement angular passes is capable of doing things beyond a standard HTML element. How does angular do this? Wrap it with jQuery first?

How does the link element in this angular-ui tinymce implementation get the tinymce method e.g. the method shown below on line 49:

elm.tinymce();

I get that the ui-tinymce attribute links to the directive named uiTinymce, and that tinymce is included in the main html, but i don’t understand how elm get the method tinymce.

As a reference I’ve provided the relevant documentation on iElement from http://docs.angularjs.org/guide/directive below.

Linking function:

function link(scope, iElement, iAttrs, controller) { ... }

The link function is responsible for registering DOM listeners as well as updating the DOM. > It is executed after the template has been cloned. This is where most of the directive logic > will be put.

scope – Scope – The scope to be used by the directive for registering watches.

iElement – instance element – The element where the directive is to be used. It is safe to manipulate the children of the element only in postLink function since the children have already been linked.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T15:16:53+00:00Added an answer on June 14, 2026 at 3:16 pm

    From the angular.element page:

    Note: All element references in Angular are always wrapped with jQuery
    or jqLite; they are never raw DOM references.

    So yes, the iElement argument is a jQueryLite, or full jQuery object, which has all of the relevant additional methods that jQuery/jQueryLite provide.

    This includes any additional methods that are added via jQuery’s plugin mechanisms, which have the effect of being able to call those methods directly on the jQuery object itself.

    So the TinyMCE JS file would have code to add in a .tinymce() function to all jQuery objects, which is how the iElement object has it.

    Does that make sense?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

angular.module('dodgie', []).config(function($routeProvider){ $routeProvider.when('/home', {template:'/partials/home.html', controller:dodgieCtrl }). otherwise({redirectTo:'/home'}); }); function dodgieCtrl($scope, $location){ $scope.doSearch = function(){
I have two Angular controllers: function Ctrl1($scope) { $scope.prop1 = First; } function Ctrl2($scope)
I was playing with angular.js the other day and I found this filter function,
Looking through angular js tutorial , I do not understand where the repeater (function?)
I have a route setup like this: var myApp = angular.module('myApp', []). config(['$routeProvider', function
My app.js contains var app = angular.module('myApp', []). config(['$routeProvider', function ($routeProvider, $http) { ...
I've got this app with two modules: angular.module('components', []).directive('foo', function () { return {};});
I have a service: (angular .module('app.services', ['ngResource']) .factory('MyService', [ /******/ '$resource', function ($resource) {
In angular I found out you can bind a template to a function which
I have this module routes: var mainModule = angular.module('lpConnect', []). config(['$routeProvider', function ($routeProvider) {

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.