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

Visual Studio 2013 freezes whenever I edit any keyword
How do I automatically (un)comment code per assembly edition?
visual basic simple calculator
Renamed visual studio project, error when publishing (ResolveAssemblyReference.cache)
MS-Access application in Visual Studio
Permanently Enable Keyboard Support For Windows Phone Emulator
Remote Debugging Azure Cloud Service
Text output tab not appearing in NUnit with ReSharper
NuGet exited with code 3
Visual Studio 2013 Community weird errors
How to get Visual Studio build process to create a distributable directory?
Microsoft.Build.Utilities.ToolLocationHelper error on TeamCity
Write script to search the solution
Tab completion for array not shows after first selection
How to force visual studio web deploy to publish the latest xap
Visual Studio 2015 RC Test Run hangs

Categories

HOME
office365
flask
webview
clearcase
android-fragments
d3.js
plpgsql
histogram
biztalk-2010
openflow
tfs2015
dji-sdk
bittorrent
clone
onvif
powermock
bundler
trace32
global-variables
fresco
vmware-workstation
rpmbuild
scala-ide
parceler
wsf
adminlte
web-analytics
jpa-2.1
window-managers
webviewclient
code-climate
dnsmasq
fotorama
epplus
osx-lion
appcode
image-optimization
custom-keyboard
bean-validation
keyboard-layout
formsauthenticationticket
redgate
jslint
mv
mars-simulator
rdp
jacoco-maven-plugin
plane
cloudera-sentry
fiware-wirecloud
contactless-smartcard
virtual-memory
dredd
cyanogenmod
winston
popen
predicates
mpmovieplayercontroller
instafeedjs
prefetch
rational-performance-test
streamwriter
android-4.2-jelly-bean
jtag
node.js-connect
maximize
jeasyui
android-async-http
persistent-object-store
onepage-checkout
ioctl
webgrind
lovefield
deeplink
miniconda
linuxbrew
place
postal-code
shell-extensions
text-align
python-c-extension
wicket-1.5
windows-rt
xulrunner
ivalueconverter
gpu-programming
roxy-fileman
typesafe-stack
meteorite
cloo
pbkdf2
saga
eclim
apache-shindig
tnt4j
xs
spiral
days
session-0-isolation
prefuse
monocross
flymake
algol68
regression-testing
solandra
explicit
self-tracking-entities
getimagesize
iphone-sdk-3.1.3
efs
word-automation

Resources

Encrypt Message



code
soft
python
ios
c
html
jquery
cloud
mobile