升级到“@nativescript/core”后找不到 Xxport 'topmost'
Xxport 'topmost' not found after upgrading to '@nativescript/core'
我的 Nativescript Vue 应用程序从 tns-core-modules
更改为 @nativescript/core
,现在我遇到了一些问题。我创建了一个类似于 this video 的模态服务。我在那里使用了导入:
import * as frameModule from 'tns-core-modules/ui/frame';
我现在改为:
import * as frameModule from "@nativescript/core";
第一个问题是这是否正确。刚找到 .
为了将模式放在前面,我使用:
frameModule.topmost()
现在导致警告:
export 'topmost' (imported as 'frameModule') was not found in '@nativescript/core'
其中一堆可能的出口。但其中 none 听起来像我需要的。
(possible exports: AbsoluteLayout, AccessibilityEvents, AccessibilityLiveRegion, AccessibilityRole, AccessibilityState, AccessibilityTrait, ActionBar, ActionItem, ActionItems, ActivityIndicator, AndroidApplication, Animation, AnimationCurve, Application, ApplicationSettings, Background, Binding, Builder, Button, CSSHelper, CSSType, CSSUtils, ChangeType, CoercibleProperty, Color, Connectivity, ContainerView, ContentView, ControlStateChangeListener, CoreTypes, CssAnimationParser, CssAnimationProperty, CssProperty, CustomLayoutView, DatePicker, Device, DialogStrings, Dialogs, DockLayout, EditableTextBase, Enums, File, FileSystemEntity, FlexboxLayout, Folder, Font, FontScaleCategory, FormattedString, Frame, GestureStateTypes, GestureTypes, GesturesObserver, GridLayout, GridUnitType, HtmlView, Http, IOSHelper, Image, ImageAsset, ImageCache, ImageSource, InheritedCssProperty, InheritedProperty, ItemSpec, KeyframeAnimation, KeyframeAnimationInfo, KeyframeDeclaration, KeyframeInfo, Label, LayoutBase, Length, ListPicker, ListView, ModuleNameResolver, NavigationButton, Observable, ObservableArray, Page, PageBase, ParserEvent, ParserEventType, PercentLength, Placeholder, Progress, Property, ProxyViewContainer, PseudoClassHandler, Repeater, RootLayout, Screen, ScrollView, SearchBar, SegmentedBar, SegmentedBarItem, ShorthandProperty, Slider, Span, StackLayout, Style, SwipeDirection, Switch, TabView, TabViewItem, TextBase, TextField, TextView, TimePicker, TouchAction, Trace, Transition, Utils, View, ViewBase, ViewHelper, VirtualArray, WebView, WrapLayout, WrappedValue, XmlParser, _setResolver, action, addTaggedAdditionalCSS, addWeakEventListener, alert, androidDynamicElevationOffsetProperty, androidElevationProperty, animationTimingFunctionConverter, autocapitalizationTypeProperty, autocorrectProperty, backgroundColorProperty, backgroundImageProperty, backgroundInternalProperty, backgroundPositionProperty, backgroundRepeatProperty, backgroundSizeProperty, booleanConverter, borderBottomColorProperty, borderBottomLeftRadiusProperty, borderBottomRightRadiusProperty, borderBottomWidthProperty, borderLeftColorProperty, borderLeftWidthProperty, borderRightColorProperty, borderRightWidthProperty, borderTopColorProperty, borderTopLeftRadiusProperty, borderTopRightRadiusProperty, borderTopWidthProperty, capitalizationType, clipPathProperty, colorProperty, confirm, dismissKeyboardOwner, dismissKeyboardTimeoutId, eachDescendant, editableProperty, encoding, fontFamilyProperty, fontInternalProperty, fontScaleProperty, fontSizeProperty, fontStyleProperty, fontWeightProperty, fromObject, fromObjectRecursive, getAncestor, getCurrentPage, getFileAccess, getRootLayout, getTransformedText, getViewById, heightProperty, hintProperty, horizontalAlignmentProperty, iOSApplication, inputType, isAndroid, isIOS, isUserInteractionEnabledProperty, keyboardTypeProperty, knownFolders, letterSpacingProperty, lineHeightProperty, login, makeParser, makeValidator, marginBottomProperty, marginLeftProperty, marginRightProperty, marginTopProperty, maxLengthProperty, minHeightProperty, minWidthProperty, opacityProperty, paddingBottomProperty, paddingLeftProperty, paddingRightProperty, paddingTopProperty, parseCSSShadow, parseKeyframeDeclarations, path, perspectiveProperty, placeholderColorProperty, platformNames, profile, profilingDisable, profilingDumpProfiles, profilingEnable, profilingIsRunning, profilingResetProfiles, profilingStart, profilingStartCPU, profilingStop, profilingStopCPU, profilingTime, profilingUptime, prompt, removeTaggedAdditionalCSS, removeWeakEventListener, resolveFileNameFromUrl, returnKeyTypeProperty, rotateProperty, rotateXProperty, rotateYProperty, sanitizeModuleName, scaleXProperty, scaleYProperty, setActivityCallbacks, textAlignmentProperty, textDecorationProperty, textShadowProperty, textTransformProperty, timeConverter, transformConverter, translateXProperty, translateYProperty, unsetValue, updateTextTriggerProperty, verticalAlignmentProperty, visibilityProperty, whiteSpaceProperty, widthProperty, zIndexProperty, zeroLength)
感谢任何帮助或猜测。
Nativescript 8 上的导入略有不同
import { Frame } from '@nativescript/core';
// and you can use it like this:
Frame.topmost()
我的 Nativescript Vue 应用程序从 tns-core-modules
更改为 @nativescript/core
,现在我遇到了一些问题。我创建了一个类似于 this video 的模态服务。我在那里使用了导入:
import * as frameModule from 'tns-core-modules/ui/frame';
我现在改为:
import * as frameModule from "@nativescript/core";
第一个问题是这是否正确。刚找到
为了将模式放在前面,我使用:
frameModule.topmost()
现在导致警告:
export 'topmost' (imported as 'frameModule') was not found in '@nativescript/core'
其中一堆可能的出口。但其中 none 听起来像我需要的。
(possible exports: AbsoluteLayout, AccessibilityEvents, AccessibilityLiveRegion, AccessibilityRole, AccessibilityState, AccessibilityTrait, ActionBar, ActionItem, ActionItems, ActivityIndicator, AndroidApplication, Animation, AnimationCurve, Application, ApplicationSettings, Background, Binding, Builder, Button, CSSHelper, CSSType, CSSUtils, ChangeType, CoercibleProperty, Color, Connectivity, ContainerView, ContentView, ControlStateChangeListener, CoreTypes, CssAnimationParser, CssAnimationProperty, CssProperty, CustomLayoutView, DatePicker, Device, DialogStrings, Dialogs, DockLayout, EditableTextBase, Enums, File, FileSystemEntity, FlexboxLayout, Folder, Font, FontScaleCategory, FormattedString, Frame, GestureStateTypes, GestureTypes, GesturesObserver, GridLayout, GridUnitType, HtmlView, Http, IOSHelper, Image, ImageAsset, ImageCache, ImageSource, InheritedCssProperty, InheritedProperty, ItemSpec, KeyframeAnimation, KeyframeAnimationInfo, KeyframeDeclaration, KeyframeInfo, Label, LayoutBase, Length, ListPicker, ListView, ModuleNameResolver, NavigationButton, Observable, ObservableArray, Page, PageBase, ParserEvent, ParserEventType, PercentLength, Placeholder, Progress, Property, ProxyViewContainer, PseudoClassHandler, Repeater, RootLayout, Screen, ScrollView, SearchBar, SegmentedBar, SegmentedBarItem, ShorthandProperty, Slider, Span, StackLayout, Style, SwipeDirection, Switch, TabView, TabViewItem, TextBase, TextField, TextView, TimePicker, TouchAction, Trace, Transition, Utils, View, ViewBase, ViewHelper, VirtualArray, WebView, WrapLayout, WrappedValue, XmlParser, _setResolver, action, addTaggedAdditionalCSS, addWeakEventListener, alert, androidDynamicElevationOffsetProperty, androidElevationProperty, animationTimingFunctionConverter, autocapitalizationTypeProperty, autocorrectProperty, backgroundColorProperty, backgroundImageProperty, backgroundInternalProperty, backgroundPositionProperty, backgroundRepeatProperty, backgroundSizeProperty, booleanConverter, borderBottomColorProperty, borderBottomLeftRadiusProperty, borderBottomRightRadiusProperty, borderBottomWidthProperty, borderLeftColorProperty, borderLeftWidthProperty, borderRightColorProperty, borderRightWidthProperty, borderTopColorProperty, borderTopLeftRadiusProperty, borderTopRightRadiusProperty, borderTopWidthProperty, capitalizationType, clipPathProperty, colorProperty, confirm, dismissKeyboardOwner, dismissKeyboardTimeoutId, eachDescendant, editableProperty, encoding, fontFamilyProperty, fontInternalProperty, fontScaleProperty, fontSizeProperty, fontStyleProperty, fontWeightProperty, fromObject, fromObjectRecursive, getAncestor, getCurrentPage, getFileAccess, getRootLayout, getTransformedText, getViewById, heightProperty, hintProperty, horizontalAlignmentProperty, iOSApplication, inputType, isAndroid, isIOS, isUserInteractionEnabledProperty, keyboardTypeProperty, knownFolders, letterSpacingProperty, lineHeightProperty, login, makeParser, makeValidator, marginBottomProperty, marginLeftProperty, marginRightProperty, marginTopProperty, maxLengthProperty, minHeightProperty, minWidthProperty, opacityProperty, paddingBottomProperty, paddingLeftProperty, paddingRightProperty, paddingTopProperty, parseCSSShadow, parseKeyframeDeclarations, path, perspectiveProperty, placeholderColorProperty, platformNames, profile, profilingDisable, profilingDumpProfiles, profilingEnable, profilingIsRunning, profilingResetProfiles, profilingStart, profilingStartCPU, profilingStop, profilingStopCPU, profilingTime, profilingUptime, prompt, removeTaggedAdditionalCSS, removeWeakEventListener, resolveFileNameFromUrl, returnKeyTypeProperty, rotateProperty, rotateXProperty, rotateYProperty, sanitizeModuleName, scaleXProperty, scaleYProperty, setActivityCallbacks, textAlignmentProperty, textDecorationProperty, textShadowProperty, textTransformProperty, timeConverter, transformConverter, translateXProperty, translateYProperty, unsetValue, updateTextTriggerProperty, verticalAlignmentProperty, visibilityProperty, whiteSpaceProperty, widthProperty, zIndexProperty, zeroLength)
感谢任何帮助或猜测。
Nativescript 8 上的导入略有不同
import { Frame } from '@nativescript/core';
// and you can use it like this:
Frame.topmost()