Commit Graph

14 Commits

Author SHA1 Message Date
Icaro Motta 9ed68ee7d1
Lint & fix some shadowed core Clojure(Script) vars (#16500)
It's well known that shadowing core Clojure vars can lead to unexpected bugs. In
fact, it's a common source of bugs in other languages too. In the status-mobile
repository there are, in total, 562 shadowed vars, ~500 are core vars. Excluding
the "old code" we still have 285 offenders.

In status-mobile I've already seen two bugs caused by shadowed vars, both with
the shadowed var "name". But probably other problems happened in the past, and
others will happen in the future if we don't do something about this. This PR is
also my response to my frustration trying to review PRs and checking for
shadowed vars, humans were not meant for that!

In this commit we are enabling ":shadowed-var" to lint certain (not all) core
vars as errors (not warnings). In future PRs we can gradually unshadow more
vars. For the record, name is shadowed 40 times in the new code and 130 in
total, and type is shadowed 93 times in the new code and 124 in total!

What about non-core vars, should we allow shadowing? There are ~70 non-core
shadowed vars. In my opinion, we should also lint and disallow shadowing
non-core vars, since it may cause the same kind of bugs of shadowing core vars.
But this decision can be left for another moment/issue, after we have fixed the
most prominent problem of shadowing core vars.

Which vars are unshadowed in this PR? I fixed 62 errors and unshadowed
cljs.core/iter, cljs.core/time, cljs.core/count, cljs.core/key,
clojure.core/key.

Resources:

- [clj-kondo linter: shadowed-var](https://github.com/clj-kondo/clj-kondo/blob/master/doc/linters.md#shadowed-var)
2023-07-06 10:28:07 +00:00
Icaro Motta 7cf17b5d34
Move unit test helper namespace to `src/test_helpers/` (#14716) 2023-01-05 11:58:37 -03:00
Icaro Motta bad796db90
Fix clojure.set and clojure.walk inconsistent namespace aliases (#14715) 2023-01-05 10:54:32 -03:00
yqrashawn 01660765b7
refactor: delete message related code (#14548) 2022-12-20 21:42:50 +08:00
Icaro Motta 5693df5a74
Lint namespace aliases (#14526) 2022-12-13 17:04:26 -03:00
Icaro Motta 6e272a96c8
Introduce subscription tests (#14472) 2022-12-06 13:36:05 -03:00
flexsurfer 31b6e076be
new structure continue, move utils, move fx macro to re-frame utils n… (#14373)
* new structure continue, move utils, move fx macro to re-frame utils namespace
2022-11-16 09:09:25 +01:00
Parvesh Monu 1047c26f69
Switcher and Bottom Tabs Animations and UI Performance Improvements
- Migrated Switcher animations to Reanimated V2
- Added bottom tabs & Stacks Animations
- Improved bottom tabs, tab changing performance
- Polished android & IOS UI
2022-06-28 23:51:24 +05:30
Gheorghe Pinzaru c7009ff6f7
Add request/approve communites
Signed-off-by: Andrea Maria Piana <andrea.maria.piana@gmail.com>
2021-02-26 15:38:19 +01:00
Gheorghe Pinzaru 12aa20f467
Add bottom sheet
EXPERIMENTAL: uses reanimated lib so we can use reanimated buttons inside and have simultaneous handlers

Add react hooks

Use hooks

mocks

Use timing for drag transition

Use view on android

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-06-02 18:10:27 +03:00
yenda 1bf68094e3
add clj-kondo to linting phase
Signed-off-by: yenda <eric@status.im>
2020-05-07 10:40:30 +02:00
Gheorghe Pinzaru 01452794a1
Add text input and tooltip components
Add tooltip component
Add text input component
rename

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-05-04 16:38:26 +03:00
yenda d5ef218584
use shadow-cljs
Signed-off-by: Jakub Sokołowski <jakub@status.im>
Signed-off-by: yenda <eric@status.im>
2020-04-30 15:43:46 +02:00
Roman Volosovskyi 0efc1a32fe
clj-kondo configuration for Status specific macroses 2019-11-26 15:16:52 +02:00