PHPackages                             webflorist/privacy-policy-text - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Localization &amp; i18n](/categories/localization)
4. /
5. webflorist/privacy-policy-text

ActiveLibrary[Localization &amp; i18n](/categories/localization)

webflorist/privacy-policy-text
==============================

Open source texts for a privacy policy in german and english. Available as php or json.

v1.5.4(4y ago)02.4k↑100%1MITPHP

Since Dec 21Pushed 3y ago1 watchersCompare

[ Source](https://github.com/webflorist/privacy-policy-text)[ Packagist](https://packagist.org/packages/webflorist/privacy-policy-text)[ Docs](https://github.com/webflorist/privacy-policy-text#readme)[ RSS](/packages/webflorist-privacy-policy-text/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (3)DependenciesVersions (26)Used By (1)

Privacy Policy Texts in German and English
==========================================

[](#privacy-policy-texts-in-german-and-english)

[![Latest Stable Composer Version](https://camo.githubusercontent.com/d1e98e030290b750e30ac5de2640f324d424540e5727ca0cc9dbc7ff0b9d532c/68747470733a2f2f706f7365722e707567782e6f72672f776562666c6f726973742f707269766163792d706f6c6963792d746578742f76)](https://packagist.org/packages/webflorist/privacy-policy-text)[![Latest Stable npm Version](https://camo.githubusercontent.com/14a5dbbf7f13ef72edb1c2b83250119f5a9064a79019365c4bb0bff4e13b5d1f/68747470733a2f2f696d672e736869656c64732e696f2f6e706d2f762f40776562666c6f726973742f707269766163792d706f6c6963792d746578742e737667)](https://www.npmjs.com/package/@webflorist/privacy-policy-text)[![License](https://camo.githubusercontent.com/a36e14aef8b3594f7571e519b19f840bef02169f2f7c3afcfef1cf42ee5ed32b/68747470733a2f2f706f7365722e707567782e6f72672f776562666c6f726973742f707269766163792d706f6c6963792d746578742f6c6963656e7365)](https://packagist.org/packages/webflorist/privacy-policy-text)

This package includes open source texts for a GDPR conform privacy policy of a website. They come in php and json files to be used by common translation frameworks.

Table Of Contents
-----------------

[](#table-of-contents)

- [Demo](#demo)
- [Features](#features)
- [Ecosystem](#ecosystem)
- [Installation](#installation)
- [Usage](#usage)
    - [In Javascript](#in-javascript)
    - [Interpolations](#interpolations)
    - [Markdown Functionality](#markdown-functionality)
- [Disclaimer](#disclaimer)
- [License](#license)

Demo
----

[](#demo)

An demo application with the texts included in this package is avaliable at:

This demo uses the package [`webflorist/privacy-policy-vue`](https://github.com/webflorist/privacy-policy-vue).

Features
--------

[](#features)

- **Languages**
    Currently the package includes texts in **german** and **english** language.
- **Singular/Plural**
    The files are provided both from singular and plural viewpoints.
    (e.g. `My website...` vs `Our website...`)
- **Formats**
    Currently the package includes files in `php` as well as `json` format.
- **Included Texts**

    - A general **intro text**
    - Listing of **GDPR rights**
    - Text to introduce **data controller**
    - General **data security** text (SSL, etc.)
    - **Cookies** information
    - Information on **data processing** of third party data processors:
        - Webhosting
        - Web analytics
        - Interactive maps
        - Sending of emails (e.g. contact forms)
    - Disclaimer regarding **outgoing links**

Ecosystem
---------

[](#ecosystem)

This package is mainly meant as a backend package for other implementations, which use it to provide a privacy policy component to a certain framework.

The following companion packages are currently available:

PackageFramework[webflorist/privacy-policy-vue](https://github.com/webflorist/privacy-policy-vue)[Vue](https://vuejs.org/)[webflorist/privacy-policy-laravel](https://github.com/webflorist/privacy-policy-laravel)[Laravel](https://laravel.com/)Installation
------------

[](#installation)

Using composer:

```
composer require webflorist/privacy-policy-text
```

Using npm:

```
npm install --save @webflorist/privacy-policy-text
```

Using yarn:

```
yarn add @webflorist/privacy-policy-text
```

Usage
-----

[](#usage)

### In Javascript

[](#in-javascript)

The ESM module exports the following stuff:

- Objects structured as `{ de: Object, en: Object}` including the translation strings with the corresponding [interpolation](#interpolations) format:

```
export const colonPrefixSingular : object
export const colonPrefixPlural : object
export const curlyWrapSingular : object
export const curlyWrapPlural : object
export const doubleCurlyWrapSingular : object
export const doubleCurlyWrapPlural : object
```

- An object with information about various processors (see [`processors.json`](https://github.com/webflorist/privacy-policy-text/blob/main/dist/json/processors.json)):

```
export const defaultProcessors : object
```

- A helper function to render the [markdown functionality](#markdown-functionality) in the language strings:

```
export function renderText(text: string): string
```

Check out the [Vue component of webflorist/privacy-policy-vue](https://github.com/webflorist/privacy-policy-vue/blob/main/dist/components/PrivacyPolicy.vue) for an example implementation.

Here is and example using a singular viewpoint and a translation library with curly-wrap [interpolations](#interpolations):

```
import { curlyWrapSingular, renderText } from '@webflorist/privacy-policy-text'
import { translate, provideTranslations } from 'my-favourite-translation-library

provideTranslations({
    de: curlyWrapSingular.de,
    en: curlyWrapSingular.en,
})

const interpolations = {
    'webhosting_processor': 'Netlify Inc.',
    'analytics_service': 'Google Analytics',
    'analytics_processor': 'Google Ireland Limited',
    'maps_service': 'Google Maps',
    'maps_processor': 'Google LLC',
    'send_emails_service': 'Twilio Sendgrid',
    'send_emails_processor': 'Twilio Inc.',
}

// Custom translation function, which uses renderText
// from @webflorist/privacy-policy-text after translation.
const t = (key) => {
    return renderText(translate(key, interpolations))
}

return `
${t('intro_content.p1')}
${t('intro_content.p2')}

    ${t('gdpr_rights.title')}
    ${t('gdpr_rights.content.p1')}

    ...
`
```

### Interpolations

[](#interpolations)

(Replacing Parameters In Translation Strings)

Any dynamic parts of the language files can be interpolated by the translation-library of your choice. The following formats are supported (each with corresponding json and php files):

- with colon prefix (`:key`)
    (e.g. used by [Laravel](https://laravel.com/docs/8.x/localization#replacing-parameters-in-translation-strings))
- wrapped with curly braces (`{key}`)
    (e.g. used by [Vue I18n](https://vue-i18n.intlify.dev/guide/essentials/syntax.html#interpolations))
- wrapped with double curly braces (`{{key}}`)
    (e.g. used by [i18next](https://www.i18next.com/translation-function/interpolation))

The following interpolations are present in the language files:

```
{
    // Name of the webhosting service
    'webhosting_service': 'Netlify Platform',
    // Company name of the webhosting processor
    'webhosting_processor': 'Netlify Inc.',

    // Name of the analytics service
    'analytics_service': 'Google Analytics',
    // Company name of the analytics processor
    'analytics_processor': 'Google Ireland Limited',

    // Name of the maps service
    'maps_service': 'Google Maps',
    // Company name of the maps processor
    'maps_processor': 'Google LLC',

    // Name of the email sending service
    'send_emails_service': 'Twilio Sendgrid',
    // Company name of the email sending processor
    'send_emails_processor': 'Twilio Inc.',
}
```

### Markdown Functionality

[](#markdown-functionality)

The language files include some markdown functionality:

- `**Bold Elements**`
- and `[Links to](#anchors)`

The package includes a `renderText(text)` function to render these markdowns. The package exports this function. So usage would be as follows:

In Javascript:

```
import { renderText } from '@webflorist/privacy-policy-text'

renderText(myTranslatedString)
```

Disclaimer
----------

[](#disclaimer)

The included text *should* be suitable for a GDPR-compliant website.

**I however do not take any responsibility whatsowever for that.**

License
-------

[](#license)

This package is open-sourced software licensed under the [MIT license](https://github.com/webflorist/privacy-policy-text/blob/main/LICENSE.md).

###  Health Score

30

—

LowBetter than 64% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity19

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 99.2% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~1 days

Total

24

Last Release

1583d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/9c2d4efd8d86101511e621cdfcc7178ba05c4854e4c4176efc0543931075fe54?d=identicon)[codeflorist](/maintainers/codeflorist)

---

Top Contributors

[![codeflorist](https://avatars.githubusercontent.com/u/41453547?v=4)](https://github.com/codeflorist "codeflorist (117 commits)")[![semantic-release-bot](https://avatars.githubusercontent.com/u/32174276?v=4)](https://github.com/semantic-release-bot "semantic-release-bot (1 commits)")

---

Tags

data-protectionenglishgdprgdpr-compliantgermanlegallocalizationprivacyprivacy-policytranslationlocalizationenglishgdprprivacylegaldata protectionPolicyprivacy policygerman

### Embed Badge

![Health badge](/badges/webflorist-privacy-policy-text/health.svg)

```
[![Health](https://phpackages.com/badges/webflorist-privacy-policy-text/health.svg)](https://phpackages.com/packages/webflorist-privacy-policy-text)
```

###  Alternatives

[symfony/intl

Provides access to the localization data of the ICU library

2.6k199.8M1.1k](/packages/symfony-intl)[commerceguys/addressing

Addressing library powered by CLDR and Google's address data.

95430.2M43](/packages/commerceguys-addressing)[gettext/languages

gettext languages with plural rules

7530.3M11](/packages/gettext-languages)[jfeltkamp/cookiesjsr

COOKiES JSR is a consent management tool and provides UI and API to manage 3rd party services within the GDPR.

27807.9k](/packages/jfeltkamp-cookiesjsr)[inpsyde/multilingual-press

Simply THE multisite-based free open source plugin for your multilingual websites.

2414.0k1](/packages/inpsyde-multilingual-press)[friends-of-contao/contao-privacy

Contao bundle that adds a privacy policy consent checkbox to the registration

252.2k](/packages/friends-of-contao-contao-privacy)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
