mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-08-19 23:13:04 +08:00
chore: refactor
This commit is contained in:
@ -10,7 +10,6 @@ import { escapeRegexSymbols } from '../../../utils';
|
|||||||
import { Trace } from '../../../trace';
|
import { Trace } from '../../../trace';
|
||||||
import * as types from '../../../utils/types';
|
import * as types from '../../../utils/types';
|
||||||
import * as bindableResources from './bindable-resources';
|
import * as bindableResources from './bindable-resources';
|
||||||
import { PolymerExpressions } from '../../../js-libs/polymer-expressions';
|
|
||||||
|
|
||||||
const contextKey = 'context';
|
const contextKey = 'context';
|
||||||
// this regex is used to get parameters inside [] for example:
|
// this regex is used to get parameters inside [] for example:
|
||||||
@ -373,7 +372,7 @@ export class Binding {
|
|||||||
|
|
||||||
private _getExpressionValue(expression: string, isBackConvert: boolean, changedModel: any): any {
|
private _getExpressionValue(expression: string, isBackConvert: boolean, changedModel: any): any {
|
||||||
try {
|
try {
|
||||||
const exp = PolymerExpressions.getExpression(expression);
|
const exp = require('../../../js-libs/polymer-expressions').PolymerExpressions.getExpression(expression);
|
||||||
if (exp) {
|
if (exp) {
|
||||||
const context = (this.source && this.source.get && this.source.get()) || global;
|
const context = (this.source && this.source.get && this.source.get()) || global;
|
||||||
const model = {};
|
const model = {};
|
||||||
|
Reference in New Issue
Block a user