Data type not found: Javascript

#1

Hei!

My name is Rafael,
I started your Hikr tutorial app to start learning Fuse, but the compiler throw me the following errors:

MainView.ux(3): E8001: Data type not found: Javascript
/Users/velcro/Documents/Work/fuse/hikr/MainView.ux(3,1): Error E8001: Data type not found: Javascript
MainView.ux(3): E8001: Could not resolve type 'Javascript'
/Users/velcro/Documents/Work/fuse/hikr/MainView.ux(3,1): Error E8001: Could not resolve type 'Javascript'

Build completed in 6.76 seconds
    2 errors
Build ended
fuse: Failed to compile project

Thanks :wink:

  • Version: 0.25.0
  • OS: OS X
0 Likes

#2

Hi, it looks like you’ve typed Javascript rather than JavaScript. UX is case-sensitive, so that doesn’t mean the same thing :slight_smile:

0 Likes

#3

Oh you’re right, my bad for not double check.

Thanks, its solved.

Cheers :wink:

0 Likes

#4

Glad to hear it :slight_smile:

0 Likes

#5

Hi every body. ich have created three components(ux:Class=“TabBar”, x:Class=“TapBar” and x:Class=“Card”. in the MainView i have:
<App Background="#ddd"
<DockPanel
<TopBar Dock=“Top”/
<Card Dock=“Center” Alignment=“Center” /
<TabBar Dock=“Bottom”/
</DockPanel
</App
and in the other Class i have:
<Rectangle ux:Class=“TopBar” Color="#63b8ff"
<Text Value=“My first app” Alignment=“Center” Margin=“20”/
</Rectangle

but i’m receiving an Errors for the three components:
Error E8001: Data type not found: TabBarC:\Users\forza\Documents\Fuse\SmallJobs\MainView.ux(5): E8001: Could not resolve type 'TabBar

What could be the Problem? thanks in avance

0 Likes

#6

Well, first off, your effort on your typing is terrible.

The compiler is saying that it can’t find the TabBar, where is your TabBar class defined?

Share your code files for us to see or use “`” three times to create code blocks like so:

<App>
More code goes here
</App>
0 Likes

#7

Hi here is my code

This is our first App ![Fuse%20Code|416x500](upload://sPwAHgRFmq2IzQuFUZUBtfteRvU.jpeg)
0 Likes

#8

@forza apart from the Dock="Center" being incorrect, the app worked as expected:

<App Background="#ddd">

	<Grid ux:Class="TabBar" ColumnCount="3" Height="60" Color="White">
		<Text Alignment="Center" Value="Left" />
		<Text Alignment="Center" Value="Center" />
		<Text Alignment="Center" Value="Right" />
	</Grid>


	<Rectangle ux:Class="Card" Color="White" CornerRadius="5" >
		<StackPanel Alignment="Center" Margin="45">
			<Text Alignment="HorizontalCenter" FontSize="35">This is</Text>
			<Text Alignment="HorizontalCenter">our</Text>
			<Text Alignment="HorizontalCenter" FontSize="25">first</Text>
			<Image Url="https://www.fusetools.com/assets/dist/images/logo-white-header.png"
				   Color="#333"
				   StretchMode="PixelPrecise"/>
			<Text Alignment="HorizontalCenter" FontSize="30">App</Text>
		</StackPanel>
	</Rectangle>


	<Rectangle ux:Class="TopBar" Color="#63b8ff">
		<Text Value="My first app" Alignment="Center" Margin="20"/>
	</Rectangle>


	<DockPanel>
		<TopBar Dock="Top"/>
		<Card   Dock="Fill" Alignment="Center" />
		<TabBar Dock="Bottom"/>
	</DockPanel>
</App>
0 Likes

#9

@forza if you want to keep the MainView.ux cleaner, you can place the classes in separate .ux files

0 Likes

#10

@aeq i solved the Problem already. it was because i created the files outside my folder but i have another problem. I want to develop a Tab bar navigation exactly like this one:https://fuseopen.com/examples/tab-bar-navigation/index.html but with defferents pages. I have created three pages ux:Class with their JavaScript pages but i think i’m facing the problem in the MainView.ux in order call those pages. If you or somebody else can give some Ideas or exemples it will be very nice. thank in avance.

forza

0 Likes

#11

@forza have a look at the PageControl documentation examples: https://fuseopen.com/docs/fuse/controls/pagecontrol.html

0 Likes