<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Mustafa Onur Çelik on Medium]]></title>
        <description><![CDATA[Stories by Mustafa Onur Çelik on Medium]]></description>
        <link>https://medium.com/@onurcelik.dev?source=rss-22abc669ed5f------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*yUNHpztYiEE9YT0iaWtSvA.jpeg</url>
            <title>Stories by Mustafa Onur Çelik on Medium</title>
            <link>https://medium.com/@onurcelik.dev?source=rss-22abc669ed5f------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 21 Nov 2026 03:27:19 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@onurcelik.dev/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Invester: A Customizable Open‑Source Investment Dashboard for Traders and Developers Alike]]></title>
            <link>https://medium.com/@onurcelik.dev/invester-a-customizable-open-source-investment-dashboard-for-traders-and-developers-alike-0a3878d985c8?source=rss-22abc669ed5f------2</link>
            <guid isPermaLink="false">https://medium.com/p/0a3878d985c8</guid>
            <category><![CDATA[trading]]></category>
            <category><![CDATA[open-source]]></category>
            <category><![CDATA[dashboard]]></category>
            <dc:creator><![CDATA[Mustafa Onur Çelik]]></dc:creator>
            <pubDate>Sat, 30 Aug 2025 18:14:18 GMT</pubDate>
            <atom:updated>2025-08-30T18:14:18.189Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*f8qONqsiLD02zTAC0UcAHw.png" /></figure><p>Creating a personal investment dashboard often means compromising — it’s either too basic, too slow, overly complex, or lacking in customization. <strong>Invester</strong> was built to break that pattern, offering a clean, real-time, and fully customizable dashboard for tracking stocks, crypto, ETFs, market news, and more — right in your browser.</p><p>You can try the live demo at <a href="https://in.vester.app/"><strong>in.vester.app</strong></a> and see it in action instantly.</p><p>This project was developed to scratch a very real itch: having a fast, flexible tool to monitor investments without relying on walled-garden platforms or heavy third-party services.</p><p>And now, it’s open-source — shared in the hope that others can benefit from it, build on top of it, and help improve it.</p><p><strong>→ GitHub Repository:</strong> <a href="https://github.com/onur-celik/invester">https://github.com/onur-celik/invester</a></p><h3>What is Invester?</h3><p>Invester is a modular React + TypeScript application that turns your browser into a live, widget-based market dashboard.</p><p>It’s lightweight, self-contained, and entirely client-side — no login or backend setup required. Just clone it, install dependencies, and start customizing your dashboard layout.</p><h3>Included Widgets</h3><p>Invester ships with a rich collection of pluggable widgets:</p><ul><li>Ticker — Real-time prices and percent changes</li><li>Mini Chart — Tiny trendlines for a quick glance</li><li>TradingView Chart Box — Fully embeddable technical charts</li><li>Economic Calendar — Major market-moving events</li><li>Crypto Fear &amp; Greed Index — Daily sentiment tracker</li><li>News Feed — Curated crypto and economy headlines</li><li>Finance TV Box — Stream live channels inside your dashboard</li><li>Notes — Keep personal notes right on the screen</li><li>Podcasts — Listen to finance-related episodes</li><li>Next Bitcoin Halving — Countdown tracker</li></ul><p>…and more coming soon</p><h3>Installation &amp; Setup</h3><p>To get started locally:</p><pre>git clone https://github.com/onur-celik/invester.git  <br>cd invester  <br>npm install  <br>npm start</pre><p>Then open your browser at <a href="http://localhost:3000/">http://localhost:3000</a> and start adding widgets.</p><p>To build for production:</p><pre>npm run build</pre><h3>Why Open Source?</h3><p>Invester was designed with flexibility and transparency in mind — so making it open-source felt like the natural next step. Whether you’re:</p><ul><li>A developer who wants to fork and extend it</li><li>A trader building custom tools for personal workflows</li><li>Or just curious about building a finance dashboard from scratch</li></ul><p>You’re more than welcome to dive in.</p><p>This is an ongoing work-in-progress, and contributions are genuinely welcome — from UI polish to new widget ideas or performance improvements.</p><h3>How to Contribute</h3><ul><li>Star the repo if you find it useful</li><li>Open issues for bugs, suggestions, or ideas</li><li>Fork and submit PRs to add features, fix issues, or improve UX</li><li>Share it with others who might benefit</li></ul><p>Invester is released under the <strong>MIT license</strong> — free to use in personal or commercial projects.</p><h3>Final Notes</h3><p>The goal of Invester isn’t to replace professional trading terminals — it’s to empower everyday investors and tinkering developers to build exactly what they need. No fees, no tracking, no walled gardens.</p><p>If that sounds like something you’d enjoy working on or using, I’d love to see where you take it.</p><p><strong>→ GitHub:</strong> <a href="https://github.com/onur-celik/invester">https://github.com/onur-celik/invester</a></p><p><strong>Contributions, ideas, or even bug reports are all appreciated.</strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=0a3878d985c8" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Python for JavaScript Developers]]></title>
            <link>https://medium.com/@onurcelik.dev/python-for-javascript-developers-020a2d9e6203?source=rss-22abc669ed5f------2</link>
            <guid isPermaLink="false">https://medium.com/p/020a2d9e6203</guid>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[development]]></category>
            <category><![CDATA[learn]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[python]]></category>
            <dc:creator><![CDATA[Mustafa Onur Çelik]]></dc:creator>
            <pubDate>Thu, 09 Jan 2025 15:07:05 GMT</pubDate>
            <atom:updated>2025-01-09T15:07:05.727Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*rGwRPrZty8hDO39d" /><figcaption>Photo by <a href="https://unsplash.com/@cmzw?utm_source=medium&amp;utm_medium=referral">MW</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>If you’re a <strong>JavaScript developer</strong> and want to dive into <strong>Python</strong>, this guide will help you get started quickly by drawing parallels between JavaScript and Python. We’ll start with the basics of project initialization and dependency management, then explore Python equivalents for common JavaScript functions, all with practical code examples.</p><p><strong>1. Starting a Project: npm vs. pip</strong></p><p><strong>JavaScript (npm)</strong></p><p>In JavaScript, you initialize a project with npm init and install dependencies using npm install. For example:</p><pre>npm init -y<br>npm install express</pre><p><strong>Python (pip)</strong></p><p>In Python, you use pip for dependency management and virtualenv to create isolated environments.</p><p>1. Create a virtual environment:</p><pre>python -m venv myenv</pre><p>2. Activate the environment:</p><p>• On Windows:</p><pre>myenv\Scripts\activate</pre><p>• On macOS/Linux:</p><pre>source myenv/bin/activate</pre><p>3. Install dependencies:</p><pre>pip install flask</pre><p>4. Save dependencies to a requirements file:</p><pre>pip freeze &gt; requirements.txt</pre><p>5. Install dependencies from a requirements file:</p><pre>pip install -r requirements.txt</pre><p><strong>2. Basic Syntax Differences</strong></p><p><strong>Hello, World!</strong></p><p>• <strong>JavaScript:</strong></p><pre>console.log(“Hello, World!”);</pre><p>• <strong>Python:</strong></p><pre>print(“Hello, World!”)</pre><p><strong>3. Variables and Data Types</strong></p><p><strong>JavaScript:</strong></p><pre>let name = “Onur”;<br>let age = 38;<br>let isDeveloper = true;</pre><p><strong>Python:</strong></p><pre>name = &quot;Onur&quot;<br>age = 30<br>is_developer = True</pre><p><strong>4. Functions</strong></p><p><strong>JavaScript:</strong></p><pre>function greet(name) {<br>  return `Hello, ${name}`;<br>}<br>console.log(greet(&quot;Onur&quot;));</pre><p><strong>Python:</strong></p><pre>def greet(name):<br>  return f&quot;Hello, {name}&quot;<br>print(greet(&quot;Onur&quot;))</pre><p><strong>5. Arrow Functions</strong></p><p>Python does not have arrow functions, but you can use <strong>lambda</strong> for concise anonymous functions.</p><p><strong>JavaScript:</strong></p><pre>const add = (a, b) =&gt; a + b;<br>console.log(add(2, 3));</pre><p><strong>Python:</strong></p><pre>add = lambda a, b: a + b<br>print(add(2, 3))</pre><p><strong>6. Loops</strong></p><p><strong>JavaScript (for loop):</strong></p><pre>for (let i = 0; i &lt; 5; i++) {<br>  console.log(i);<br>}</pre><p><strong>Python (for loop):</strong></p><pre>for i in range(5):<br>  print(i)</pre><p><strong>7. Arrays vs. Lists</strong></p><p><strong>JavaScript (Array):</strong></p><pre>const fruits = [&quot;apple&quot;, &quot;banana&quot;, &quot;cherry&quot;];<br>console.log(fruits[1]);</pre><p><strong>Python (List):</strong></p><pre>fruits = [&quot;apple&quot;, &quot;banana&quot;, &quot;cherry&quot;]<br>print(fruits[1])</pre><p><strong>8. Objects vs. Dictionaries</strong></p><p><strong>JavaScript (Object):</strong></p><pre>const person = { name: &quot;Onur&quot;, age: 30 };<br>console.log(person.name);</pre><p><strong>Python (Dictionary):</strong></p><pre>person = {&quot;name&quot;: &quot;Onur&quot;, &quot;age&quot;: 30}<br>print(person[&quot;name&quot;])</pre><p><strong>9. Promises vs. Async/Await</strong></p><p><strong>JavaScript:</strong></p><pre>const fetchData = async () =&gt; {<br>  const data = await fetch(&quot;https://api.example.com&quot;);<br>  console.log(await data.json());<br>};<br>fetchData();</pre><p><strong>Python:</strong></p><pre>import asyncio<br>import aiohttp<br><br>async def fetch_data():<br>  async with aiohttp.ClientSession() as session:<br>    async with session.get(&quot;https://api.example.com&quot;) as response:<br>      print(await response.json())<br>asyncio.run(fetch_data())</pre><p><strong>10. Common JavaScript Functions and Their Python Equivalents</strong></p><p><strong>JavaScript — — — — — — — — — — — — — -Python</strong></p><pre>Math.max(1, 2, 3)               -&gt;   max(1, 2, 3)<br>Math.min(1, 2, 3)               -&gt;   min(1, 2, 3)<br>arr.map(x =&gt; x * 2)             -&gt;   [x * 2 for x in arr]<br>arr.filter(x =&gt; x &gt; 2)          -&gt;   [x for x in arr if x &gt; 2]<br>arr.reduce((a, b) =&gt; a + b)     -&gt;   sum(arr)<br>setTimeout(() =&gt; {}, 1000)      -&gt;   import time; time.sleep(1)<br>JSON.stringify(obj)             -&gt;   import json; json.dumps(obj)<br>JSON.parse(str)                 -&gt;   import json; json.loads(str)</pre><p><strong>11. File Handling</strong></p><p><strong>JavaScript:</strong></p><pre>const fs = require(&quot;fs&quot;);<br><br>fs.writeFileSync(&quot;example.txt&quot;, &quot;Hello, World!&quot;);<br>const content = fs.readFileSync(&quot;example.txt&quot;, &quot;utf8&quot;);<br>console.log(content);</pre><p><strong>Python:</strong></p><pre>with open(&quot;example.txt&quot;, &quot;w&quot;) as file:<br>  file.write(&quot;Hello, World!&quot;)<br><br>with open(&quot;example.txt&quot;, &quot;r&quot;) as file:<br>  content = file.read()<br>  print(content)</pre><p><strong>12. Bonus</strong></p><p>Example of a Flask app:</p><pre>from flask import Flask<br><br>app = Flask(__name__)<br><br>@app.route(&quot;/&quot;)<br>def home():<br>  return &quot;Hello, World!&quot;<br><br>if __name__ == &quot;__main__&quot;:<br>  app.run(debug=True)</pre><p><strong>Conclusion</strong></p><p>This guide has introduced the key differences and similarities between JavaScript and Python, helping you leverage your existing JavaScript knowledge to learn Python efficiently. Start experimenting with Python by setting up small projects, and you’ll find it to be a versatile and powerful language for various use cases.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=020a2d9e6203" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Three Spark: A Boilerplate for Three.js Projects]]></title>
            <link>https://medium.com/@onurcelik.dev/three-spark-a-boilerplate-for-three-js-projects-4fb73c0ecc46?source=rss-22abc669ed5f------2</link>
            <guid isPermaLink="false">https://medium.com/p/4fb73c0ecc46</guid>
            <category><![CDATA[boilerplate]]></category>
            <category><![CDATA[open-source]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[threejs]]></category>
            <dc:creator><![CDATA[Mustafa Onur Çelik]]></dc:creator>
            <pubDate>Sat, 04 Jan 2025 19:14:11 GMT</pubDate>
            <atom:updated>2025-01-04T19:14:11.714Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*A80OmbVivyr8SZxnu9PEcQ.jpeg" /><figcaption>Three Spark Demo</figcaption></figure><p><strong>Three Spark: A Boilerplate for Three.js Projects</strong></p><p>Working with <a href="https://threejs.org/"><strong>Three.js</strong></a> to create stunning 3D web experiences can be exciting, but setting up a project from scratch often feels repetitive. From configuring tools to organizing your files and adding libraries, it takes time before you can actually start building.</p><p>That’s where <a href="https://github.com/onur-celik/three-spark"><strong>Three Spark</strong></a> comes in — a streamlined boilerplate designed to help you kickstart your Three.js projects quickly and efficiently.</p><p><strong>What is Three Spark?</strong></p><p>Three Spark is an <strong>open-source boilerplate</strong> for developers working with Three.js. It eliminates the hassle of setting up a new project by providing a pre-configured environment, complete with essential tools to enhance your workflow.</p><p>The boilerplate includes:</p><p>• <strong>TypeScript</strong>: Adds type safety and improves code maintainability.</p><p>• <strong>dat.GUI</strong>: Enables quick UI controls for real-time parameter adjustments.</p><p>• <strong>GSAP</strong>: Provides smooth and customizable animations.</p><p>• <strong>Webpack</strong>: Simplifies the bundling and development process.</p><p>Three Spark also comes with a <strong>live demo</strong> that showcases its default setup. You can check it out here: <a href="https://onur-celik.github.io/three-spark/"><strong>Three Spark Demo</strong></a>.</p><p><strong>How to Get Started</strong></p><p>1. <strong>Clone the repository</strong>:</p><pre>git clone https://github.com/onur-celik/three-spark</pre><pre>cd three-spark</pre><p>2. <strong>Install dependencies</strong>:</p><pre>npm install</pre><p>3. <strong>Run the development server</strong>:</p><pre>npm run dev</pre><p>4. <strong>View your project</strong>:</p><p>Open <a href="http://localhost:8080/">http://localhost:8080</a> in your browser to see a basic Three.js scene in action.</p><p>The starter scene includes a rotating cube, providing a solid foundation to experiment with geometries, lights, and animations. You can modify the src folder to expand the demo or build your own project.</p><p><strong>Why Use Three Spark?</strong></p><p>Three Spark is perfect for developers who:</p><p>• Want to avoid repetitive setup tasks and dive straight into development.</p><p>• Need a clean and modular starting point for experimenting with Three.js.</p><p>• Appreciate having pre-configured tools like TypeScript, GSAP, and dat.GUI in one package.</p><p><strong>Ready to Spark Your Creativity?</strong></p><p>If you’re ready to start your next Three.js project with ease, visit the <a href="https://github.com/onur-celik/three-spark"><strong>Three Spark GitHub Repository</strong></a>.</p><p>Don’t forget to explore the <a href="https://onur-celik.github.io/three-spark/"><strong>live demo</strong></a> to see it in action!</p><p>Feedback and contributions are welcome, so let’s build something amazing together.</p><p>Happy coding! 🎨✨</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4fb73c0ecc46" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Comparing A* and Dijkstra’s Algorithm in Three.js]]></title>
            <link>https://medium.com/@onurcelik.dev/comparing-a-and-dijkstras-algorithm-in-three-js-94eb18e5ec27?source=rss-22abc669ed5f------2</link>
            <guid isPermaLink="false">https://medium.com/p/94eb18e5ec27</guid>
            <category><![CDATA[threejs]]></category>
            <category><![CDATA[comparison]]></category>
            <category><![CDATA[a-star-algorithm]]></category>
            <category><![CDATA[dijkstras-algorithm]]></category>
            <category><![CDATA[performance]]></category>
            <dc:creator><![CDATA[Mustafa Onur Çelik]]></dc:creator>
            <pubDate>Thu, 20 Jun 2024 08:18:16 GMT</pubDate>
            <atom:updated>2024-06-20T08:18:16.615Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*aY5WcA9BW5_qNLn5" /><figcaption>Photo by <a href="https://unsplash.com/@familyschaffner?utm_source=medium&amp;utm_medium=referral">Astrid Schaffner</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>When implementing pathfinding in Three.js, two popular algorithms often come into play: A* and Dijkstra’s. Both are widely used for navigating graphs and finding the shortest path, but they have key differences in terms of efficiency and application. Understanding these differences can help you choose the best algorithm for your Three.js project.</p><h4>Dijkstra’s Algorithm</h4><p>Dijkstra’s algorithm, developed by Edsger Dijkstra in 1956, is a classic algorithm for finding the shortest path between nodes in a graph. It works by exploring all possible paths from the starting node to the target node, ensuring that the shortest path is found. Here’s a brief overview of how it works:</p><ol><li><strong>Initialization</strong>: Set the distance to the starting node to zero and to all other nodes to infinity.</li><li><strong>Visit Nodes</strong>: Start with the initial node, visit its neighbors, and update their distances based on the shortest known path.</li><li><strong>Update Paths</strong>: Continue visiting the unvisited node with the smallest known distance. Update the distances of its neighbors.</li><li><strong>Repeat</strong>: Repeat until all nodes have been visited or the shortest path to the target node is determined.</li></ol><p><strong>Advantages of Dijkstra’s Algorithm</strong>:</p><ul><li><strong>Optimal Solution</strong>: Guarantees the shortest path in graphs with non-negative weights.</li><li><strong>Simple Implementation</strong>: Straightforward to implement and understand.</li></ul><p><strong>Disadvantages of Dijkstra’s Algorithm</strong>:</p><ul><li><strong>Efficiency</strong>: It can be slow for large graphs because it explores all possible paths.</li><li><strong>No Heuristics</strong>: It does not use heuristics to improve performance.</li></ul><h4>A* Algorithm</h4><p>A* algorithm, introduced by Peter Hart, Nils Nilsson, and Bertram Raphael in 1968, is an extension of Dijkstra’s algorithm. It incorporates heuristics to guide the search, making it more efficient in many cases. Here’s how it works:</p><ol><li><strong>Initialization</strong>: Set the distance to the starting node to zero and to all other nodes to infinity. Also, calculate the heuristic estimate (often the Euclidean distance) from each node to the target.</li><li><strong>Visit Nodes</strong>: Start with the initial node, visit its neighbors, and update their distances based on the shortest known path plus the heuristic estimate.</li><li><strong>Update Paths</strong>: Continue visiting the node with the smallest combined distance and heuristic estimate. Update the distances of its neighbors.</li><li><strong>Repeat</strong>: Repeat until the target node is reached or all possible paths are explored.</li></ol><p><strong>Advantages of A* Algorithm</strong>:</p><ul><li><strong>Efficiency</strong>: Often faster than Dijkstra’s because it uses heuristics to focus the search.</li><li><strong>Optimal Solution</strong>: Still guarantees the shortest path if the heuristic is admissible (does not overestimate distances).</li></ul><p><strong>Disadvantages of A* Algorithm</strong>:</p><ul><li><strong>Heuristic Dependency</strong>: Performance heavily depends on the quality of the heuristic. A poor heuristic can degrade performance.</li><li><strong>Complexity</strong>: Slightly more complex to implement due to the heuristic component.</li></ul><h4>Comparison in Three.js</h4><p>When using these algorithms in a Three.js project, consider the specific requirements of your application:</p><ul><li><strong>Dijkstra’s Algorithm</strong>: Best suited for smaller graphs or when you need guaranteed optimal paths without the need for heuristics. It’s straightforward but can be slow for larger graphs.</li><li><strong>A* Algorithm</strong>: Ideal for larger graphs where efficiency is crucial. The heuristic helps focus the search, making it faster in practice. However, selecting an appropriate heuristic is key to maintaining performance.</li></ul><p>In summary, both algorithms have their strengths and weaknesses. Dijkstra’s algorithm is reliable and simple, but can be slow for large graphs. A* algorithm, with its heuristic guidance, offers better performance for larger graphs, making it a more practical choice for most Three.js pathfinding applications.</p><p>Choosing between the two depends on your specific needs: if simplicity and guaranteed optimal paths are your priority, Dijkstra’s is a good choice. If efficiency and handling larger graphs are more important, A* is likely the better option.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=94eb18e5ec27" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to remove Expo from a React Native project]]></title>
            <link>https://medium.com/@onurcelik.dev/how-to-remove-expo-from-a-react-native-project-ba19a1621ff4?source=rss-22abc669ed5f------2</link>
            <guid isPermaLink="false">https://medium.com/p/ba19a1621ff4</guid>
            <category><![CDATA[expo]]></category>
            <category><![CDATA[react-native]]></category>
            <category><![CDATA[mobile-development]]></category>
            <dc:creator><![CDATA[Mustafa Onur Çelik]]></dc:creator>
            <pubDate>Thu, 05 Jan 2023 06:42:02 GMT</pubDate>
            <atom:updated>2023-01-05T06:42:02.158Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*9L4AMwgWTnuk_sEA" /><figcaption>Photo by <a href="https://unsplash.com/@sigmund?utm_source=medium&amp;utm_medium=referral">Sigmund</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>To remove Expo from a React Native project, you will need to “eject” the project from the Expo managed workflow. This process will create a new native project that you can build and run on your own, without the need for the Expo client app.</p><p>To eject your project from Expo, you will need to run the following command in your project directory:</p><pre>expo eject</pre><p>This will prompt you to choose between two options:</p><ul><li><strong>Eject to a managed workflow:</strong> This option will create a new native project using Expo’s managed workflow, which includes tools like CRNA (<strong>Create React Native App</strong>) and ExpoKit. This option is recommended if you want to continue using Expo’s tools and services, but want more control over the native build process.</li><li><strong>Eject to an un-managed workflow: </strong>This option will create a new native project that is not managed by Expo. This option is recommended if you want to use your own build tools and workflows, such as <strong>Xcode</strong> or <strong>Android Studio</strong>.</li></ul><p>After you have made your selection, Expo will create a new native project and update your project files to reflect the changes. You will then be able to build and run your app using the native tools and workflows of your choice.</p><p>It is important to note that once you have ejected your project, you will no longer be able to use the Expo client app to build and run your app. You will need to use the native tools and workflows to build and run your app going forward.</p><p>For more information about ejecting a project from Expo, you can refer to the <a href="https://docs.expo.dev/expokit/eject/">Expo documentation</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ba19a1621ff4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Testing React code]]></title>
            <link>https://medium.com/@onurcelik.dev/testing-react-code-8217ca7e0d79?source=rss-22abc669ed5f------2</link>
            <guid isPermaLink="false">https://medium.com/p/8217ca7e0d79</guid>
            <category><![CDATA[reactjs]]></category>
            <category><![CDATA[tdd]]></category>
            <category><![CDATA[testing]]></category>
            <category><![CDATA[react]]></category>
            <dc:creator><![CDATA[Mustafa Onur Çelik]]></dc:creator>
            <pubDate>Thu, 05 Jan 2023 06:29:30 GMT</pubDate>
            <atom:updated>2023-01-05T06:29:30.828Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*dhXn6Bi3GwOabD2-" /><figcaption>Photo by <a href="https://unsplash.com/@ninjason?utm_source=medium&amp;utm_medium=referral">Jason Leung</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>There are several ways you can test React code:</p><ol><li><strong>Unit testing:</strong> This involves writing small, isolated tests that focus on specific parts of your code, such as individual functions or components. These tests can help you ensure that your code is working as expected and catch any bugs early on.</li><li><strong>Enzyme:</strong> This is a library developed by Airbnb that makes it easier to test React components. It provides a set of functions that allow you to simulate actions on your components and make assertions about their behavior.</li><li><strong>Jest:</strong> This is a JavaScript testing framework that is often used with React. It includes a test runner, an assertion library, and a set of utility functions for working with React components.</li><li><strong>Testing Library:</strong> This is a collection of libraries that makes it easier to test React components in a way that is more closely aligned with how users interact with them.</li></ol><p>To get started with testing your React code, you can choose a testing library or framework that you feel comfortable with and follow the documentation to set it up in your project. Then, you can start writing tests for your components and functions to ensure that they are working as expected.</p><h3><strong>Here is an example of a simple test using Jest:</strong></h3><pre>const sum = require(&#39;./sum&#39;);<br><br>test(&#39;adds 1 + 2 to equal 3&#39;, () =&gt; {<br>  expect(sum(1, 2)).toBe(3);<br>});</pre><p>This test is testing a function called sum that takes in two arguments and returns the sum of those arguments. The test function is a way to define a test case in Jest, and the expect function is used to make an assertion about the expected output of the function. In this case, we are using the toBe matcher to assert that the value returned by sum(1, 2) is equal to 3.</p><p>If the function being tested behaves as expected, the test will pass. If the function returns an unexpected result, the test will fail.</p><p>Jest also provides other matchers that you can use to make assertions about the output of your code. For example, you can use toEqual to test for deep equality, toBeNull to test for null values, and toBeTruthy to test for truthy values.</p><p>For more information about Jest and how to use it to test your code, you can refer to the <a href="https://jestjs.io/docs/getting-started"><strong>Jest documentation</strong></a>.</p><h3><strong>Here is an example of how you might use Enzyme to test a simple React component:</strong></h3><pre>import React from &#39;react&#39;;<br>import { shallow } from &#39;enzyme&#39;;<br>import MyComponent from &#39;./MyComponent&#39;;<br><br>describe(&#39;MyComponent&#39;, () =&gt; {<br>  it(&#39;renders a title&#39;, () =&gt; {<br>    const wrapper = shallow(&lt;MyComponent /&gt;);<br>    expect(wrapper.find(&#39;.title&#39;).text()).toEqual(&#39;Hello World&#39;);<br>  });<br>});</pre><p>This test is testing a component called MyComponent that is expected to render a title element with the text &quot;Hello World&quot;. The shallow function is used to create a shallow rendering of the component, which means that it only renders the component itself and not any of its children. The find method is used to find an element with the class title within the component, and the text method is used to retrieve the text content of that element. Finally, the toEqual matcher is used to assert that the text content is equal to &quot;Hello World&quot;.</p><p>If the component behaves as expected, the test will pass. If the component does not render a title element with the correct text, or if the element is not found, the test will fail.</p><p>Enzyme provides a variety of other methods and functions that you can use to test your React components, such as mount for full DOM rendering, and simulate for simulating events. You can refer to the <a href="https://enzymejs.github.io/enzyme/"><strong>Enzyme documentation</strong></a> for more information.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8217ca7e0d79" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to calculate net profit / loss on a trade]]></title>
            <link>https://medium.com/@onurcelik.dev/how-to-calculate-net-profit-loss-on-a-trade-c143d3b8d59e?source=rss-22abc669ed5f------2</link>
            <guid isPermaLink="false">https://medium.com/p/c143d3b8d59e</guid>
            <category><![CDATA[trading]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[cryptocurrency]]></category>
            <dc:creator><![CDATA[Mustafa Onur Çelik]]></dc:creator>
            <pubDate>Thu, 05 Jan 2023 06:02:13 GMT</pubDate>
            <atom:updated>2023-01-05T06:02:13.781Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*7cnq9deV7AOOkObm" /><figcaption>Photo by <a href="https://unsplash.com/@jsnbrsc?utm_source=medium&amp;utm_medium=referral">Jason Briscoe</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>To calculate the net profit or loss on a cryptocurrency trade, you will need to consider the following steps:</p><ol><li>Determine the price at which you bought the cryptocurrency. This is known as your cost basis.</li><li>Determine the price at which you sold the cryptocurrency. This is known as the sale price.</li><li>Subtract your cost basis from the sale price to determine the gross profit or loss.</li><li>Subtract any fees or commissions that were incurred during the trade. These may include broker fees, exchange fees, or other charges.</li><li>Calculate the net profit or loss by subtracting the fees and commissions from the gross profit or loss.</li></ol><p>For example, let’s say you bought 1 unit of cryptocurrency X for $100 and later sold it for $110. The gross profit from the trade would be $10 ($110 — $100). If you incurred a $1 commission during the trade, your net profit would be $9 ($10 — $1).</p><p>Here is an example of how you could calculate the net profit or loss in JavaScript:</p><pre>// Define variables for the cost basis and sale price<br>const costBasis = 100;<br>const salePrice = 110;<br><br>// Define a variable for the commission rate<br>const commissionRate = 0.01; // 1% commission rate<br><br>// Calculate the gross profit or loss<br>const grossProfit = salePrice - costBasis;<br><br>// Calculate the buying and selling commissions<br>const buyingCommission = costBasis * commissionRate;<br>const sellingCommission = salePrice * commissionRate;<br><br>// Calculate the net profit or loss by subtracting the buying and selling commissions from the gross profit or loss<br>const netProfit = grossProfit - buyingCommission - sellingCommission;<br><br>console.log(`The net profit is ${netProfit}`);</pre><p>This code will output the following message to the console: “The net profit is 8”</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c143d3b8d59e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Publishing your code as an npm package in 5 simple steps]]></title>
            <link>https://medium.com/@onurcelik.dev/publishing-your-code-as-an-npm-package-in-5-simple-steps-f5a5dfbd3e62?source=rss-22abc669ed5f------2</link>
            <guid isPermaLink="false">https://medium.com/p/f5a5dfbd3e62</guid>
            <category><![CDATA[development]]></category>
            <category><![CDATA[npm]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[npm-package]]></category>
            <dc:creator><![CDATA[Mustafa Onur Çelik]]></dc:creator>
            <pubDate>Tue, 20 Dec 2022 22:54:23 GMT</pubDate>
            <atom:updated>2022-12-20T22:54:23.365Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*t9yUJ9EV0bTIYrqS" /><figcaption>Photo by <a href="https://unsplash.com/@nublson?utm_source=medium&amp;utm_medium=referral">Nubelson Fernandes</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>To publish a package to the <a href="https://www.npmjs.com/">npm</a> registry, you will need to have an npm account and be logged in to your account. Here are the steps to publish a package:</p><ol><li>Make sure your package is ready to be published. This means that it should have a valid package.json file, with all necessary fields filled out, and should be in a clean, working state.</li><li>Navigate to the root directory of your package.</li><li>Run the npm login command and enter your npm account credentials when prompted. This will log you in to your npm account.</li><li>Run the npm publish command. This will publish your package to the npm registry.</li><li>If you want to update your package, make the necessary changes and then run the npm publish command again. npm will automatically increment the package version number based on the changes you made.</li></ol><p>It’s a good idea to test your package locally before publishing it, to make sure it is working as expected. You can do this by creating a new project and installing your package locally using the npm install command.</p><p>Keep in mind that once you publish a package, it becomes publicly available and can’t be deleted. It’s a good idea to carefully consider whether a package is ready for public release before publishing it.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f5a5dfbd3e62" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[From front end development to mobile development]]></title>
            <link>https://medium.com/@onurcelik.dev/from-front-end-development-to-mobile-development-32448e12c72e?source=rss-22abc669ed5f------2</link>
            <guid isPermaLink="false">https://medium.com/p/32448e12c72e</guid>
            <category><![CDATA[development]]></category>
            <category><![CDATA[mobile-development]]></category>
            <category><![CDATA[front-end-development]]></category>
            <dc:creator><![CDATA[Mustafa Onur Çelik]]></dc:creator>
            <pubDate>Tue, 20 Dec 2022 22:47:14 GMT</pubDate>
            <atom:updated>2022-12-20T22:47:14.511Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*KyQXCI0Lu_RbbnIY" /><figcaption>Photo by <a href="https://unsplash.com/@halacious?utm_source=medium&amp;utm_medium=referral">Hal Gatewood</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>As a front-end developer, you already have a strong foundation in web development and a good understanding of how to build user interfaces. To become a mobile developer, you can follow these steps:</p><ol><li><strong>Choose a mobile development platform:</strong> There are several platforms for mobile development, including iOS, Android, and cross-platform frameworks such as <a href="https://docs.flutter.dev/">Flutter</a>, <a href="https://reactnative.dev/docs/getting-started">React Native</a>, and <a href="https://learn.microsoft.com/en-us/xamarin/">Xamarin</a>. Choose the platform that aligns with your goals and interests.</li><li><strong>Learn the programming languages and tools:</strong> Each mobile platform has its own set of programming languages and tools. For example, iOS development typically involves using <a href="https://www.swift.org/documentation/">Swift</a> or Objective-C, while Android development involves using Java or <a href="https://kotlinlang.org/">Kotlin</a>. Familiarize yourself with the languages and tools used for the platform you have chosen.</li><li><strong>Understand the differences between web and mobile development:</strong> While there are many similarities between web and mobile development, there are also some key differences. Mobile devices have smaller screens and limited processing power, so you need to consider factors such as performance and battery life when building mobile apps. You also need to consider how users will interact with your app on a mobile device, as well as the different form factors and screen sizes of various devices.</li><li><strong>Build mobile apps:</strong> Start building mobile apps to gain practical experience and get a feel for the development process. You can build simple apps to begin with, and gradually increase the complexity as you become more comfortable with the platform.</li><li><strong>Stay up to date:</strong> Mobile development is a rapidly evolving field, so it’s important to stay up to date with the latest technologies, frameworks, and best practices. Consider joining online communities, attending meetups and conferences, and taking online courses to continue learning and improving your skills.</li></ol><p>Continually learning and improving your skills, you can become a successful mobile developer as a front-end developer.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*9-s9a2IM6oQoqocK" /><figcaption>Photo by <a href="https://unsplash.com/@robman?utm_source=medium&amp;utm_medium=referral">Rob Hampson</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><h3>Differences between web and mobile development</h3><p>Web development and mobile development have many similarities, as both involve building applications that can be accessed through a device with a screen and an internet connection. However, there are also some key differences between the two:</p><ol><li><strong>Device capabilities:</strong> Mobile devices have smaller screens and limited processing power compared to desktop computers, so you need to consider factors such as performance and battery life when building mobile apps. You also need to consider how users will interact with your app on a mobile device, as well as the different form factors and screen sizes of various devices.</li><li><strong>Platforms:</strong> Web development is platform-agnostic, meaning that the same website can be accessed from any device with a web browser. Mobile development, on the other hand, involves building apps for specific platforms, such as iOS or Android. Each platform has its own set of programming languages, tools, and guidelines that you need to understand in order to build apps for it.</li><li><strong>Distribution:</strong> Web applications are typically accessed through a web browser, whereas mobile apps are downloaded and installed on a device. This means that mobile apps need to be distributed through app stores, which have their own set of guidelines and approval processes that you need to follow.</li><li><strong>User experience: </strong>The user experience of web and mobile apps can differ significantly. Web apps tend to be accessed from desktop computers, which have larger screens and more processing power, so they can be more interactive and feature-rich. Mobile apps, on the other hand, need to be optimized for smaller screens and limited processing power, so they may be simpler and more focused on specific tasks.</li></ol><p>Understanding these differences, you can better tailor your development efforts to the specific needs of web or mobile development.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=32448e12c72e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Backtesting a trading strategy with JavaScript]]></title>
            <link>https://medium.com/trading-data-analysis/backtesting-a-trading-strategy-with-javascript-f9561997dca?source=rss-22abc669ed5f------2</link>
            <guid isPermaLink="false">https://medium.com/p/f9561997dca</guid>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[algorithmic-trading]]></category>
            <category><![CDATA[backtesting]]></category>
            <dc:creator><![CDATA[Mustafa Onur Çelik]]></dc:creator>
            <pubDate>Mon, 19 Dec 2022 18:46:34 GMT</pubDate>
            <atom:updated>2022-12-20T16:29:50.221Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*8dbNpMUiQg7-r2_Q" /><figcaption>Photo by <a href="https://unsplash.com/@cdr6934?utm_source=medium&amp;utm_medium=referral">Chris Ried</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>Backtesting is the process of testing a trading strategy by applying it to historical data to see how it would have performed in the past. Here is an example of how you might write JavaScript code to backtest a trading strategy:</p><ol><li>Collect historical data for the asset or market that you want to trade. This data should include prices, volumes, and any other relevant information that your strategy uses to make decisions.</li><li>Write a function that implements your trading strategy. This function should take in the historical data as input and return a series of buy and sell signals based on the strategy.</li><li>Write a function to simulate the execution of the strategy. This function should take in the historical data and the series of buy and sell signals, and should simulate the buying and selling of the asset according to the signals. It should also keep track of the performance of the strategy, such as the profit or loss, the number of trades, and any other relevant metrics.</li><li>Call the strategy simulation function, passing in the historical data and the series of buy and sell signals generated by the trading strategy function. The simulation function will then execute the strategy and output the performance metrics.</li></ol><p>Here is an example of how these functions might be implemented in JavaScript:</p><pre>// Function to implement a trading strategy<br>function tradingStrategy(data) {<br>  // Implement your trading strategy here, using the data as input<br>  // Return an array of buy and sell signals, with 1 indicating a buy signal and -1 indicating a sell signal<br>  const signals = [];<br><br>  // Example strategy: buy when the price is above the moving average, sell when the price is below the moving average<br>  const movingAverage = calculateMovingAverage(data);<br>  for (let i = 0; i &lt; data.length; i++) {<br>    if (data[i].price &gt; movingAverage) {<br>      signals.push(1);<br>    } else if (data[i].price &lt; movingAverage) {<br>      signals.push(-1);<br>    } else {<br>      signals.push(0);<br>    }<br>  }<br><br>  return signals;<br>}</pre><pre>// Function to simulate the execution of a trading strategy<br>function simulateStrategy(data, signals) {<br>  // Initialize variables to track the performance of the strategy<br>  let numTrades = 0;<br>  let profit = 0;<br>  let position = 0; // 0 = no position, 1 = long position, -1 = short position<br><br>  // Loop through the data and signals, simulating the buying and selling of the asset according to the signals<br>  for (let i = 0; i &lt; data.length; i++) {<br>    if (signals[i] === 1 &amp;&amp; position === 0) {<br>      // Buy the asset<br>      position = 1;<br>      numTrades++;<br>      profit -= data[i].price;<br>    } else if (signals[i] === -1 &amp;&amp; position === 1) {<br>      // Sell the asset<br>      position = 0;<br>      numTrades++;<br>      profit += data[i].price;<br>    } else if (signals[i] === -1 &amp;&amp; position === 0) {<br>      // Sell the asset short<br>      position = -1;<br>      numTrades++;<br>      profit += data[i].price;<br>    } else if (signals[i] === 1 &amp;&amp; position === -1) {<br>      // Buy the asset to cover the short position<br>      position = 0;<br>      numTrades++;<br>      profit -= data[i].price;<br>    }<br>  }<br><br>  // Calculate the final profit or loss<br>  if (position === 1) {<br>    profit += data[data.length - 1].price;<br>  } else if (position === -1) {<br>    profit -= data[data.length - 1].price;<br>  }<br><br>  // Return an object with the performance metrics of the strategy<br>  return {<br>    numTrades: numTrades,<br>    profit: profit<br>  };<br>}</pre><p>To complete the backtesting process, you would then need to call the simulateStrategy function and pass in the historical data and the series of buy and sell signals generated by the tradingStrategy function. For example:</p><pre>const data = [<br>  // Historical data for the asset or market<br>];<br>const signals = tradingStrategy(data);<br>const results = simulateStrategy(data, signals);<br><br>console.log(results); // Output: object with the performance metrics of the strategy</pre><p>The simulateStrategy function should output an object with the performance metrics of the strategy, such as the profit or loss, the number of trades, and any other relevant metrics. You can then use these metrics to evaluate the effectiveness of the strategy and make any necessary adjustments.</p><p>It’s important to note that backtesting is just one step in the process of developing and evaluating a trading strategy. It’s a useful tool for testing the logic and mechanics of a strategy, but it has limitations and cannot fully account for real-world market conditions and other factors that can affect the performance of a strategy. It’s always a good idea to also test a strategy on live market data to see how it performs in real-time.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f9561997dca" width="1" height="1" alt=""><hr><p><a href="https://medium.com/trading-data-analysis/backtesting-a-trading-strategy-with-javascript-f9561997dca">Backtesting a trading strategy with JavaScript</a> was originally published in <a href="https://medium.com/trading-data-analysis">Trading Data Analysis</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>