Skip to main content

Source Code Branding Strategy — PhotoFlowSEO

Question: Should we rebrand "PhotoSwipe" references in src/ to "PhotoFlowSEO"?

Answer: NO — Keep MIT-licensed code intact with original PhotoSwipe references.


Dual-License Strategy Explained

What We Have

src/
├── js/ ← MIT License (PhotoSwipe original)
│ ├── photoswipe.js
│ ├── lightbox/
│ └── ...
├── photoswipe.css ← MIT License (PhotoSwipe original)
└── pro/ ← Proprietary (PhotoFlowSEO extensions)
├── ai/
├── licensing/
└── payment/

Correct Approach: Hybrid Branding

DirectoryLicenseBrandStrategy
src/js/MIT (PhotoSwipe)Keep "PhotoSwipe"Do NOT rebrand
src/photoswipe.cssMIT (PhotoSwipe)Keep "PhotoSwipe"Do NOT rebrand
src/pro/ProprietaryUse "PhotoFlowSEO"Can rebrand
Marketing/DocsN/AUse "PhotoFlowSEO"Already done ✓
Package nameN/AUse "photoflowseo"Already done ✓

Why Keep MIT Code Unchanged?

The MIT License requires:

"The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software."

What this means:

  • We MUST keep Dmitry Semenov's copyright intact
  • We MUST keep "PhotoSwipe" references in MIT-licensed code
  • Changing class names/function names is technically allowed BUT creates confusion about attribution

2. Clear Attribution

Keeping "PhotoSwipe" in the base code makes it crystal clear:

  • PhotoSwipe = MIT-licensed base (free, open source)
  • PhotoFlowSEO = Our commercial product (PhotoSwipe + Pro extensions)

Example in code:

// src/js/photoswipe.js (MIT)
class PhotoSwipe extends PhotoSwipeBase {
// Original PhotoSwipe code
}

// src/pro/ai/plugin.js (Proprietary)
/**
* PhotoFlowSEO AI SEO Plugin
* Extends PhotoSwipe with AI-powered alt text and schema
*/
export function createAiSeoPlugin(opts) {
// Our proprietary code
}

3. Developer Expectations

Developers familiar with PhotoSwipe expect:

  • Class name: PhotoSwipe
  • Import: import PhotoSwipe from 'photoflowseo'
  • API: new PhotoSwipe(options)

If we rename the class to PhotoFlowSEO, we break:

  • ❌ Existing PhotoSwipe knowledge
  • ❌ Muscle memory
  • ❌ Documentation consistency

4. Differentiation Strategy Alignment

Per differentiation-strategy.md:

What's the same: Gallery UI/UX (PhotoSwipe foundation) What's different: PhotoFlowSEO (AI SEO automation)

Keeping PhotoSwipe in the code reinforces this: "Built on PhotoSwipe, enhanced by PhotoFlowSEO"


What SHOULD Be Branded as PhotoFlowSEO

✅ Package & Distribution

  • Package name: photoflowseo (not photoswipe-pro)
  • GitHub repo: photoflowseo
  • Domain: photoflowseo.com

✅ Marketing & Docs

  • Website copy: "PhotoFlowSEO"
  • README: "PhotoFlowSEO"
  • Docs pages: "PhotoFlowSEO"
  • Email addresses: @photoflowseo.com

✅ Proprietary Code (src/pro/)

  • Comments/JSDoc can reference "PhotoFlowSEO"
  • File headers for new files can say "PhotoFlowSEO"
  • License validation messages: "PhotoFlowSEO license"

✅ License Keys

  • Prefix: pfs_ (not pswp_)
  • Env var: PHOTOFLOWSEO_KEY

What SHOULD NOT Be Rebranded

❌ MIT-Licensed Base Code (src/js/, src/photoswipe.css)

Keep unchanged:

  • Class names: PhotoSwipe, PhotoSwipeLightbox
  • Function names (PhotoSwipe API)
  • CSS class names: .pswp, .pswp__*
  • Comments referring to "PhotoSwipe"
  • JSDoc @typedef names

Why?

  1. MIT attribution requirement
  2. API compatibility
  3. Clear lineage (MIT vs Proprietary)

❌ Third-Party References

  • Links to photoswipe.com (original project)
  • References to Dmitry Semenov
  • MIT License text

Example: Correct Hybrid Branding

File: src/js/photoswipe.js (MIT)

/**
* PhotoSwipe
* by Dmitry Semenov
* https://photoswipe.com
*
* MIT License
*/

class PhotoSwipe extends PhotoSwipeBase {
// Keep all "PhotoSwipe" references
}

✅ Correct: Keep original PhotoSwipe branding

File: src/pro/ai/plugin.js (Proprietary)

/**
* PhotoFlowSEO AI SEO Plugin
* Copyright (c) 2025 [Your Company Name]
*
* Extends PhotoSwipe with AI-powered alt text and schema generation
*
* Proprietary License - See LICENSE-commercial
*/

export function createAiSeoPlugin(opts) {
// Our proprietary PhotoFlowSEO code
}

✅ Correct: Use PhotoFlowSEO branding in our extensions

File: package.json

{
"name": "photoflowseo",
"description": "PhotoFlowSEO - AI-powered SEO automation for product galleries. Built on PhotoSwipe.",
"keywords": ["seo", "ai", "photoswipe", "gallery"]
}

✅ Correct: Package is "photoflowseo", but we credit PhotoSwipe

File: README.md

# PhotoFlowSEO

**SEO metadata that flows automatically from your product images**

Built on [PhotoSwipe](https://photoswipe.com) by Dmitry Semenov.

✅ Correct: Our brand is PhotoFlowSEO, base is PhotoSwipe


NOTICE File Update

Update NOTICE to reflect PhotoFlowSEO:

PhotoFlowSEO
Copyright (c) 2025 [Your Company Name]

This software is built on PhotoSwipe, which is licensed under the MIT License:

PhotoSwipe
Copyright (c) 2014-2022 Dmitry Semenov
https://photoswipe.com
...

PhotoFlowSEO AI SEO extensions (located in src/pro/) are proprietary
and licensed under the terms in LICENSE-commercial.

CSS Class Names

Keep PhotoSwipe Prefixes

/* src/photoswipe.css - MIT */
.pswp { }
.pswp__bg { }
.pswp__scroll-wrap { }

✅ Keep: These are part of the MIT-licensed PhotoSwipe

PhotoFlowSEO Extensions Can Use New Prefixes

/* src/pro/ai-seo.css - Proprietary (if we add one) */
.photoflowseo-badge { }
.photoflowseo-schema-preview { }

✅ Optional: New proprietary features can use new prefixes


Developer Experience

What Developers See

1. Installation:

npm install photoflowseo

"I'm installing PhotoFlowSEO"

2. Import:

import PhotoSwipe from 'photoflowseo';
import { createAiSeoPlugin } from 'photoflowseo/ai-seo';

"I'm importing PhotoSwipe (the gallery) and PhotoFlowSEO's AI plugin"

3. Usage:

const lightbox = new PhotoSwipe(options);
const ai = createAiSeoPlugin({ licenseKey: 'pfs_xxx' });

"I'm using PhotoSwipe (base) with PhotoFlowSEO AI features"

Result: Clear distinction between base (PhotoSwipe) and extensions (PhotoFlowSEO)


Comparison: Right vs Wrong Approach

❌ WRONG: Rebrand Everything

// src/js/photoswipe.js
class PhotoFlowSEO extends PhotoFlowSEOBase {
// Problems:
// 1. Violates MIT attribution spirit
// 2. Confuses developers
// 3. Breaks PhotoSwipe compatibility claims
// 4. Legal gray area
}

✅ RIGHT: Hybrid Branding

// src/js/photoswipe.js (MIT - unchanged)
class PhotoSwipe extends PhotoSwipeBase { }

// src/pro/ai/plugin.js (Proprietary - PhotoFlowSEO)
/**
* PhotoFlowSEO AI SEO Plugin
*/
export function createAiSeoPlugin(opts) { }

Action Items

✅ Already Correct (Keep As-Is)

  • src/js/ — All PhotoSwipe references intact
  • src/photoswipe.css — All .pswp classes intact
  • Package name: photoflowseo
  • Marketing: "PhotoFlowSEO"
  • Docs: "PhotoFlowSEO"

🔧 Need Updates

  • Update NOTICE file: "PhotoSwipe Pro" → "PhotoFlowSEO"
  • Ensure src/pro/ comments reference PhotoFlowSEO (not PhotoSwipe Pro)
  • Add JSDoc to src/pro/ files clarifying they're PhotoFlowSEO extensions

❌ Do NOT Do

  • ❌ Do NOT rename PhotoSwipe class
  • ❌ Do NOT rebrand src/js/ code
  • ❌ Do NOT change .pswp CSS classes
  • ❌ Do NOT remove Dmitry Semenov attributions

TL;DR

Question: Should we rebrand "PhotoSwipe" in src/ to "PhotoFlowSEO"?

Answer: NO

Strategy:

  • Keep MIT base unchanged (src/js/, CSS) — PhotoSwipe branding
  • Brand proprietary extensions (src/pro/) — PhotoFlowSEO branding
  • Brand package/marketing — PhotoFlowSEO
  • Clear attribution — "Built on PhotoSwipe"

Result: Legal compliance + Clear differentiation + Developer trust

Status: ✅ Already correct! No source code rebranding needed.