Lease Agreement Generator

Lease Agreement Generator

Parties & Property Information

Landlord Details

Tenant(s) Details

Leased Property Details

Lease Term & Rent Details

Utilities & Additional Terms

Utility Responsibilities

Review Your Lease Agreement

The Landlord agrees to lease to the Tenant the property located at: ${getValue('propertyAddress')}.

Description: ${getValue('propertyDescription')}.

3. Term

The term of this lease is ${leaseTerm}, beginning on ${formatDate(getValue('startDate'))} and ending on ${endDateText}.

4. Rent

The Tenant agrees to pay a monthly rent of $${getValue('monthlyRent')}. Rent is due on the ${getValue('rentDueDate')}.

A late fee will be applied as follows: ${getValue('lateFee')}.

5. Security Deposit

Upon execution of this Agreement, the Tenant shall deposit with the Landlord the sum of $${getValue('securityDeposit')} as a security deposit.

6. Utilities

The responsibilities for utilities are as follows:

${utilityHtml}

7. Additional Terms

Smoking Policy: ${getValue('smokingPolicy')}.

Pet Policy: ${petPolicyText}.

Additional Clauses: ${getValue('additionalClauses') || 'None.'}

_________________________

Landlord Signature

_________________________

Tenant Signature

`; } // Function to handle the PDF download process function downloadPDF() { const { jsPDF } = window.jspdf; const pdfContent = document.getElementById('pdf-output'); if (!pdfContent) { console.error("PDF content area not found."); return; } // Use html2canvas to render the div to a canvas html2canvas(pdfContent, { scale: 2 }).then(canvas => { const imgData = canvas.toDataURL('image/png'); // A4 dimensions in mm const pdfWidth = 210; const pdfHeight = 297; const canvasWidth = canvas.width; const canvasHeight = canvas.height; const canvasAspectRatio = canvasWidth / canvasHeight; // Calculate image dimensions to fit A4 page width const imgWidth = pdfWidth - 20; // with margin const imgHeight = imgWidth / canvasAspectRatio; const doc = new jsPDF({ orientation: 'p', unit: 'mm', format: 'a4' }); let position = 10; // top margin // If content is taller than one page, split it if (imgHeight > pdfHeight - 20) { let heightLeft = imgHeight; let currentPosition = 0; while(heightLeft > 0) { doc.addImage(imgData, 'PNG', 10, position, imgWidth, imgHeight, undefined, 'FAST'); heightLeft -= (pdfHeight - 20); if (heightLeft > 0) { doc.addPage(); // The position needs to be negative to show the next part of the image position -= (pdfHeight - 15); } } } else { doc.addImage(imgData, 'PNG', 10, 10, imgWidth, imgHeight); } doc.save('Lease-Agreement.pdf'); }); } });
Scroll to Top