Cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

tools.js is imported by app/index.js, but could not be resolved

ANSWERED

I haven't made any changes to my clock face any a long time (5 months ago or more).  I logged into the studio.fitbt.com today to add calories to my clockface.  I tried to build and was told to pick a SDK Version; I picked 3.1 and tried to build again and got the error "tools.js is imported by app/index.js, but could not be resolved".  Then I tried SDK 3.0 and got the same thing.

 

Is there something I need to change since I was forced to select a SDK version.

 

The code is out on GitHub: https://github.com/grumpy-coders/rpg-time

 

Best Answer
0 Votes
1 BEST ANSWER

Accepted Solutions

If you're not already doing so, try specifying imports to local files using relative references; eg,

Spoiler
import './tools.js'
You might need .. depending on how you've structured your files.
Peter McLennan
Gondwana Software

View best answer in original post

Best Answer
3 REPLIES 3

Update: 

I tried another one of my apps. 

All I did was open the IDE (studio.fitbit.com) and press build.  Forced to select an SDK version.  Same error with a different js file: DeviceInfo.js is imported by app/classes/GameState.js, but could not be resolved.

Best Answer
0 Votes

If you're not already doing so, try specifying imports to local files using relative references; eg,

Spoiler
import './tools.js'
You might need .. depending on how you've structured your files.
Peter McLennan
Gondwana Software
Best Answer

The "./"  was the key. 

 

I had tried "app/tools.js" and "./app/tools.js"  but not "./tools.js"

 

I'm not sure what changed because it used to work; but thanks that fixed it.

Best Answer
0 Votes