Working on Windows 10 Environment
Error from web server on windows 10:
'''
Failed to load resource: the server responded with a status of 404 (Not Found)
app.js:56 Uncaught (in promise) ReferenceError: TruffleContract is not defined
at Object.loadContract (app.js:56)
at async Object.load (app.js:8)
'''
Code referenced in error:
'''
loadContract: async () => {
//var contract = require("truffle-contract");
// Create a JavaScript version of the smart contract
const todoList = await $.getJSON('vote.json')
console.log(todoList)
App.contracts.TodoList = TruffleContract(todoList)
App.contracts.TodoList.setProvider(App.web3Provider)
// Hydrate the smart contract with values from the blockchain
App.todoList = await App.contracts.TodoList.deployed()
},
'''