visual-studio


Ionic: Error: Module build failed: Error: ENOENT: no such file or directory


I am using Ionic, and get the following error:
Runtime Error Uncaught (in promise): Error: Module build failed:
Error: ENOENT: no such file or directory, open
'/Users/richardmarais/Development/ionic/theWhoZoo/src/pages/model/ratingModel.js'
The error is a result of this line of code:
this.ratingModel = new RatingModel();
When I remove this line, I don't get the error.
ratingModel.ts
import { Injectable } from "#angular/core";
import { PersonModel } from './personModel';
import { JobModel } from './jobModel';
#Injectable()
export class RatingModel {
public id: number = null;
public job: JobModel = null;
public review: string = null;
public rating: number = null;
public reviewDate: number = null;
public time: string = null;
public person: PersonModel = null;
public anonymous: number = null;
constructor() {
}
}
Reading other forums, people are getting this error due to the case not matching in their imports, but I have checked mine, and they do match.
import { RatingModel } from '../model/ratingModel';
However, I have noticed something strange in my IDE (Visual Studio Code):
As you can see, in the search results, there are two files for the object, ratingModel.ts and RatingModel.ts. But when I check the actual files system, there is only on file, ratingModel.ts:
Question
Does anyone know what and how to resolve what looks like possibly a bug or fault here?
Thanks
More info:
global packages:
#ionic/cli-utils : 1.0.0
Cordova CLI : 6.4.0
Ionic CLI : 3.0.0
local packages:
#ionic/app-scripts : 1.3.0
#ionic/cli-plugin-cordova : 1.0.0
#ionic/cli-plugin-ionic-angular : 1.0.0
Ionic Framework : ionic-angular 3.2.1
System:
Node : v7.10.0
OS : macOS Sierra
Xcode : Xcode 8.3.2 Build version 8E2002
ios-deploy : not installed
ios-sim : not installed

Related Links

Compiling IFCPlusPlus with VS2015 create huge libraries
Debug ActiveX in JScript using Iexplorer
Missing project references on fresh visual studio install
Cordova - Insert to web page's database
Xamarin unable to connect to Mac from Visual Studio 2013
Time-Stamping servers API (what signtool uses)
Why is MSB3245 not failing the build?
SSIS - debugging not working
How do I break on debug output in Visual Studio 2013?
Where is the WCF Test Client in Visual Studio 2015
Build error in Visual Studio with assembly
Mass Importing of projects into TFS
Can CUDA Toolkit 7.5 be used on Visual Studio 2015 with VS 2013 Platform Toolkit
Reintegrate a branch back to the trunk when sweeping changes have been made to the tree structure
How to replace the Top Link Bar with promoted Links on SharePoint 2013
Is there a way how to import keyboard shortcuts from IntelliJ to Visual Studio 2015

Categories

HOME
user-interface
powerbi
writefile
activex
code-formatting
out-of-memory
ios-simulator
semantic-web
ontology
static-analysis
log4j2
yahoo
cname
ex
stimulsoft
temperature
google-tasks-api
google-sites
deepfreeze
bluemix-mobile-services
gitkraken
weex
cell
software-packaging
web-push
tortoisemerge
window-managers
uri
tf-idf
math.js
ccavenue
splunk-query
credit-card
xenapp
windowsiot
mapnik
delayed-job
nsmutablearray
cloudera-manager
kendo-listview
ms-media-foundation
markov-chains
code-rally
twilio-php
microsoft-ui-automation
netapp
secure-coding
moinmoin
nonlinear-functions
palindrome
pecl
maatwebsite-excel
portal
researchkit
java-2d
streamwriter
jenkins-workflow
declarative
fiber
gnucash
textblock
mercurial-extension
wepay
http.client
highest
pythonxy
domino-designer-eclipse
alwayson
explain
webproject
nsmutabledata
utf8-decode
nesper
relationships
xhprof
box2dweb
hyperloglog
gpu-programming
lync-2010
django-sites
mft
revmob
jquery-transit
tnt4j
ax
indesign-server
blobstorage
contextswitchdeadlock
workflow-manager-1.x
border-box
image-formats
coordinate
pcspim
kolite
will-paginate
snackjs
vows
nsconnection
anonymous-types
turbine
hungarian-notation
icicles
isapi-redirect
html-generation

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App