We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cool project thanks for sharing with us.
Using numeric trait values causes the build-rarities script to miss actual tokens at this line: https://github.com/cryptoDevAmigos/rarity-analyzer/blob/main/packages/common-node/src/build-rarities.ts#L133
It ends up showing as [Missing] in the filtering functionality on the left nav which is undesirable given that the value is not actually missing;
[Missing]
I solved this on my fork by coercing the value to a string for equality matching:
.filter(t=>t.attributeRarities.some(a=>a.trait_type === x.trait_type && String(a.value) === String(x.value)))
There may be a better solution but this worked for me.
The text was updated successfully, but these errors were encountered:
Worth noting that due to the rarity calculator 0 is still not a valid trait value:
This line filters out 0
const allAttributesRaw = metadata.flatMap(x => x.attributes).filter(x => !!x.value);
Nice chart here
value │ !value │ !!value ━━━━━━━━━━━┿━━━━━━━━━━┿━━━━━━━━━━━ false │ ✔ true │ false true │ false │ ✔ true null │ ✔ true │ false undefined │ ✔ true │ false 0 │ ✔ true │ false -0 │ ✔ true │ false 1 │ false │ ✔ true -5 │ false │ ✔ true NaN │ ✔ true │ false '' │ ✔ true │ false 'hello' │ false │ ✔ true
Sorry, something went wrong.
No branches or pull requests
Cool project thanks for sharing with us.
Using numeric trait values causes the build-rarities script to miss actual tokens at this line:
https://github.com/cryptoDevAmigos/rarity-analyzer/blob/main/packages/common-node/src/build-rarities.ts#L133
It ends up showing as
[Missing]
in the filtering functionality on the left nav which is undesirable given that the value is not actually missing;I solved this on my fork by coercing the value to a string for equality matching:
There may be a better solution but this worked for me.
The text was updated successfully, but these errors were encountered: