The NBA Lineup Optimizer is a web application that allows users to calculate the optimal lineup for DraftKings contests. Users can input a specific DraftKings contest ID, and the application will fetch player data, calculate the optimal lineup based on the players' projected points and salaries, and display the results.
- Fetch player data based on a DraftKings contest ID
- Calculate the optimal lineup for the contest
- Display player data in a table
- Display the optimal lineup in a separate table
- Show total salary and projected points for the optimal lineup
- Install Node.js if you haven't already.
- Clone the repository: git clone https://github.com/Ollstar/lineupoptimizer.git
- Navigate to the project directory: cd lineupoptimzer
- Install the required dependencies: npm install
- Create a
.env
file in the project root directory with the following content: WEB_URL=your_website_url_here (Use http://localhost:3000 for local) Replaceyour_website_url_here
with the URL of your website. This is required for the application to work properly. (Use local) - Start the server: npm run dev
- Open your web browser and visit
http://localhost:3000
. The application should now be running.
- Enter a DraftKings contest ID in the input field.
- Click the "Update Players" button to fetch the player data for the entered contest ID. The player data will be displayed in the "All Players" table.
- Click the "Calculate Optimal Lineup" button. The application will calculate the optimal lineup and display it in the "Optimal Lineup" table along with the total salary and projected points.
I welcome contributions to the NBA Lineup Optimizer project! Please follow these steps to contribute:
- Fork the repository.
- Create a new branch in your fork with a descriptive name related to the changes you plan to make.
- Make your changes in the new branch.
- Commit and push your changes to your fork.
- Create a pull request to the main repository with a clear and concise description of your changes.
Before submitting your pull request, please make sure your changes are well-tested and follow the project's coding style.
The NBA Lineup Optimizer is open-source software licensed under the MIT License. Please see the LICENSE file for more information.