Moltivie / the-t3-stack

Avoid .bind() or local functions in JSX properties JS-0417
Performance
Major
a year ago2 years old
JSX props should not use arrow functions
161                          className={`w-fit rounded-md border border-gray-200 bg-transparent px-4 py-3 font-semibold text-gray-200 transition duration-200 hover:bg-gray-200 hover:text-gray-800 ${
162                            userIsRegistered && "pointer-events-none opacity-30"
163                          }`}
164                          onClick={handleSubmit}165                          disabled={
166                            userRegisteredisLoading ||
167                            mutationRegister.isLoading ||
JSX props should not use arrow functions
145                {session && (session.user?.role || 1) > 1 && (
146                  <button
147                    type="button"
148                    onClick={handleCreate}149                    disabled={createUserMutation.isLoading}
150                  >
151                    <li