|
Last change
on this file was 9af201e, checked in by MBK <marija.karapandzova@…>, 2 weeks ago |
|
Fix frontend appearance
|
-
Property mode
set to
100644
|
|
File size:
444 bytes
|
| Rev | Line | |
|---|
| [9af201e] | 1 | 'use strict';
|
|---|
| 2 |
|
|---|
| 3 | /**
|
|---|
| 4 | * Create a bound version of a function with a specified `this` context
|
|---|
| 5 | *
|
|---|
| 6 | * @param {Function} fn - The function to bind
|
|---|
| 7 | * @param {*} thisArg - The value to be passed as the `this` parameter
|
|---|
| 8 | * @returns {Function} A new function that will call the original function with the specified `this` context
|
|---|
| 9 | */
|
|---|
| 10 | export default function bind(fn, thisArg) {
|
|---|
| 11 | return function wrap() {
|
|---|
| 12 | return fn.apply(thisArg, arguments);
|
|---|
| 13 | };
|
|---|
| 14 | }
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.