Experimenting with AIOHA package & trying to integrate it in flutter project
Hello @techcoderx
Saw your annoucement that now you are @vibecoderx
& was april-fooled for almost 1 hour 🤣
Realized only after reading comments
Understanding Setup
Let's get to the subject. I am experimenting with AIOHA & trying to integrate it in Flutter project. As you know that, flutter project supports multiple platforms. My flutter project intends to support web, iOS & Android. To start with, I'm focusing on web support.
Here is how flutter-web-app folder structure looks like.
I have added following script tag in body.
<script type="module">
import * as Aioha from "./aioha@1.6.0-beta.4.js";
window.Aioha = Aioha;
console.log("Aioha initialized", aioha);
aiohaInitialized = true;
</script>
In another script tag, I've added following code to make sure that I access AIOHA only after it is available.
var aiohaInitialized = false;
let aioha = null;
async function someFunctionToUse(some, params) {
if (!aiohaInitialized) {
console.error("Aioha not initialized");
// try again after few miliseconds when aioha@1.6.0-beta.4.js is available/downloaded
return;
}
if (aioha === null) {
// we have aioha.js, let's set up an aioha instance
aioha = window.Aioha.initAioha({
hiveauth: {
name: "AiohaExperiments",
description: "Testing aioha login - keychain & hiveauth methods",
},
});
}
// we are good to go to use aioha
}
Understanding Error
HiveKeychain based login works very well & I didn't face any error. However, HiveAuth started giving me error.
So, when I tried logging in with HiveAuth, I got error.
Error from console
Network Tab from Chrome Inspector
Next Steps
- I request @techcoderx to look into this issue.
- I assume by bundling together, we can avoid that issue. I'm not js/front-end expert here so may be I am wrong.
- Once, this issue is solved, I'll switch to iOS & Android integration
❤️ Love the work I do, support @threespeak & me ❤️
This post has been manually curated by @bhattg from Indiaunited community. Join us on our Discord Server.
Do you know that you can earn a passive income by delegating to @indiaunited. We share more than 100 % of the curation rewards with the delegators in the form of IUC tokens. HP delegators and IUC token holders also get upto 20% additional vote weight.
Here are some handy links for delegations: 100HP, 250HP, 500HP, 1000HP.
100% of the rewards from this comment goes to the curator for their manual curation efforts. Please encourage the curator @bhattg by upvoting this comment and support the community by voting the posts made by @indiaunited.
Thank you @bhattg & @indiaunited for support
via Inbox
Challenging but impressive work, @sagarkothari88! Respect! 👍
!DIY
!POB
!CCC
Thank you @acgalarza
via Inbox
Cool! 🎉 AIOHA in Flutter for web, iOS, & Android sounds ambitious. Excited to see your progress, especially web support! Keep us updated. 😉
What is AIOHA ?
All in one Hive Authentication
Developed by one of top Hive Witness - @techcoderx
https://peakd.com/@aioha/posts
via Inbox
Aioha core is code-splitted by default to keep main bundle size as small as possible, dependencies from some providers are only loaded when it is being used. If you're not using the CDN or
pnpm i
you have to download all vendor bundles which arehiveauth-aes.bundle.js
andledger.bundle.js
from the same place where you downloaded the main bundle.Okay. I'll give that a try & let you know. Thank you @techcoderx for quick reply.
via Inbox
Hmm, wht new tools are you building now...
3Speak Mobile Application - All over again
Packages/Libraries which I used have expired
For a new release, I must start from scratch
via Inbox
Anything related to online trade...
nope
via Inbox