dappuniversity / eth-todo-list

Blockchain Todo App Tutorial Powered by Ethereum Smart Contracts
560 stars 550 forks source link

TruffleContract is not define #42

Open yash061102 opened 1 year ago

yash061102 commented 1 year ago
Screenshot 2023-04-18 at 12 49 45 AM
Yash-verma18 commented 1 year ago

The given index.html is old, hence most of the scripts url is outdated, Replace all the scripts in index.html file with the following :

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>
<!-- Include all compiled plugins (below), or include individual files as needed -->
<script src="vendor/bootstrap/dist/js/bootstrap.min.js"></script>

<!-- following truffle contract is retarder/old -->
<!-- <script src="vendor/truffle-contract/dist/truffle-contract.js"></script> -->
<script src="https://cdn.jsdelivr.net/npm/truffle-contract@4.0.31/dist/truffle-contract.min.js"></script>

<script src="https://cdn.jsdelivr.net/gh/ethereum/web3.js@1.x/dist/web3.min.js"></script>

<script src="app.js"></script>