-
Notifications
You must be signed in to change notification settings - Fork 4.7k
docs/improve hacktoberfest readme #10603
New issue
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
base: main
Are you sure you want to change the base?
docs/improve hacktoberfest readme #10603
Conversation
- Add beginner-friendly authentication tutorial
- docs: enhance Hacktoberfest guide with contributor tips\n\n- Add comprehensive tips for new contributors\n- Include pre-contribution guidelines and best practices \n- Provide post-submission advice for better engagement\n- Emphasize quality over quantity for meaningful contributions
Added a complete tutorial showing basic auth flow with Appwrite: - User registration and login forms - Profile display and logout - Session management - Error handling examples - Common troubleshooting tips This fills a gap I noticed - most examples show individual methods but not how they work together in a real app. Perfect for developers just starting with Appwrite who want to understand the full authentication flow. Based on my own experience learning Appwrite - this tutorial would have saved me hours when I was getting started!
…rehensive tips for new contributors\n- Include pre-contribution guidelines and best practices \n- Provide post-submission advice for better engagement\n- Emphasize quality over quantity for meaningful contributions
📝 WalkthroughWalkthroughAdds a new “Quick Tips for New Contributors” section to HACKTOBERFEST.md with guidance before starting, making contributions, post-PR steps, and a closing reminder. Introduces a new documentation tutorial at docs/tutorials/simple-auth-flow.md describing a complete Appwrite-based authentication flow for a simple web app. The tutorial includes HTML layout, JavaScript initialization (Client/Account), registration, email/password session login, fetching current user, logout, UI state handling, error handling, a check-on-load routine, common issues, next steps, and a full combined example. Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
import { Client, Account } from "appwrite"; | ||
|
||
// Initialize the Appwrite client | ||
const client = new Client() | ||
.setEndpoint('https://cloud.appwrite.io/v1') // Replace with your endpoint | ||
.setProject('YOUR_PROJECT_ID'); // Replace with your project ID | ||
|
||
const account = new Account(client); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix ES module usage in the browser example.
The tutorial loads Appwrite via a CDN script tag, but auth.js
still uses import { Client, Account } from "appwrite";
. In a plain browser setup that isn’t marked type="module"
, this syntax throws and the tutorial fails. Since the CDN already exposes Appwrite
on window
, drop the import and instantiate through the global:
-import { Client, Account } from "appwrite";
-
// Initialize the Appwrite client
-const client = new Client()
+const client = new Appwrite.Client()
.setEndpoint('https://cloud.appwrite.io/v1')
.setProject('YOUR_PROJECT_ID');
-const account = new Account(client);
+const account = new Appwrite.Account(client);
Apply the same change in the “Complete Code” section so the two snippets stay in sync.
Also applies to: 222-230
🤖 Prompt for AI Agents
In docs/tutorials/simple-auth-flow.md around lines 80-88 (and likewise 222-230),
the browser example incorrectly uses ES module imports (import { Client, Account
} from "appwrite";) while the page loads Appwrite via CDN and is not using
type="module". Remove the import lines and instantiate the SDK from the global
window.Appwrite object instead (use new Appwrite.Client() and new
Appwrite.Account(client)), and make the identical change in the “Complete Code”
section so both snippets remain consistent.
Security Scan Results for PRDocker Image Scan Results
Source Code Scan Results🎉 No vulnerabilities found! |