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

Publish ClickOnce app to local machine and then upload?
Visual Studio: debug information in release build
What is the fastest way to jump to a constructor(s) in a class?
Is my Visual Studio project a web application or a web site?
Can Visual Studio Package built in VS2005 be deployed on VS2010?
What is the Visual Studio registry settings to make IDE tabs MRU-sorted?
How do I show the description box of the properties window in Visual Studio 2010 if it is hidden?
Quick method to correct Entity Framework's missed “singularizations”?
Pick which Visual Studio to open old .sln-s with Visual Studio's Version Selector
How do you a configure a Visual Studio custom build tool to depend on a lot of files?
Using Eclipse CDT with VisualStudio compiler
TFS and Unit testing: How to find all failing test caused by my recent undelivered changes?
Is there a keyboard shortcut in Xcode to move cursor to the first character of the current line? [duplicate]
Delphi equivalent to Ctrl+K+D in Visual Studio?
Visual Studio add-in/extension for adding/removing/handling references easily
Missing snippet in visual studio

Categories

HOME
rust
oracle
artificial-intelligence
eclipse-plugin
operating-system
nsis
tibco
scheduler
mailing-list
asp.net-core-1.0
jqxgrid
playframework-2.0
cpu-usage
scheduled-tasks
jitsi
spring-ldap
akka-persistence
backtracking
fido-u2f
conda
device
mod-wsgi
sap-lumira
ccavenue
basic-authentication
social-networking
d3.js-v4
winsock
argv
reporting
kendo-listview
restful-architecture
pdfminer
formsauthenticationticket
testlink
runtimeexception
djcelery
django-crispy-forms
widestring
right-click
jacoco-maven-plugin
icepdf
distributed-caching
contactless-smartcard
ipp-protocol
brightscript
nonlinear-functions
amazon-elastic-beanstalk
winmerge
case-when
msxml
openquery
decoder
ftp-client
deferred-rendering
maximize
frame-grab
android-async-http
polymerfire
flipclock
wepay
featuretoggle
alwayson
clarion
mxe
findersync
maven-shade-plugin
tkx
device-admin
zend-mail
qt5.4
jquery-mobile-flipswitch
nidaqmx
nachos
cpu-time
typesafe-stack
assetic
jmenubar
node.js-stream
xs
flv
instance-variables
cakeyframeanimation
liveconnect
nsfont
exponent
fork-join
azure-acs
git-log
downgrade
self-tracking-entities
resharper-5.0
html-components
fuzzy-comparison
autobench
rakudo

Resources

Encrypt Message